Skip to content
This repository was archived by the owner on Nov 30, 2023. It is now read-only.

Commit e0ad62b

Browse files
author
Amblizer
committed
1. fix "test-project/bin" missing
2. add auto clean test-project after debug 3. hard coding relative path
1 parent 0c96b4d commit e0ad62b

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

75 files changed

+12
-1153
lines changed

containers/ruby-2-rails-5/.devcontainer/devcontainer.json

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,7 @@
44
"extensions": [
55
"rebornix.Ruby",
66
],
7-
"runArgs": [
8-
// change this to your project name to debug
9-
"-e", "PROJECT_NAME=test-project"
10-
],
7+
"runArgs": [],
118
// Uncomment the next line if you want to publish any ports.
129
// "appPort": ["80:80"],
1310

containers/ruby-2-rails-5/.vscode/launch.json

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,10 +9,11 @@
99
"type": "Ruby",
1010
"request": "launch",
1111
// Current dir using env variable input in tasks.json
12-
"cwd": "${workspaceRoot}/${env:PROJECT_NAME}",
12+
"cwd": "${workspaceRoot}/test-project",
1313
// run bundle install before rails server
14-
"preLaunchTask": "bundleInstall",
14+
"preLaunchTask": "Create test-project",
1515
"program": "bin/rails",
16+
"postDebugTask": "Delete test-project",
1617
// Setup debug binding IP and port.
1718
"args": ["s", "-b", "0.0.0.0", "-p", "80"],
1819
}

containers/ruby-2-rails-5/.vscode/tasks.json

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,10 +3,15 @@
33
// for the documentation about the tasks.json format
44
"version": "2.0.0",
55
"tasks": [
6-
{ // bundle install in project folder
7-
"label": "bundleInstall",
6+
{
7+
"label": "Create test-project",
88
"type": "shell",
9-
"command": "cd ${env:PROJECT_NAME} && bundle install"
9+
"command": "rails new test-project -G --skip && cd test-project && bundle install"
10+
},
11+
{
12+
"label": "Delete test-project",
13+
"type": "shell",
14+
"command": "cd test-project && rm -rf * && rm -f .ruby-version"
1015
},
1116
],
1217
}

containers/ruby-2-rails-5/test-project/.gitignore

Lines changed: 0 additions & 31 deletions
This file was deleted.

containers/ruby-2-rails-5/test-project/.ruby-version

Lines changed: 0 additions & 1 deletion
This file was deleted.

containers/ruby-2-rails-5/test-project/Gemfile

Lines changed: 0 additions & 62 deletions
This file was deleted.

containers/ruby-2-rails-5/test-project/Gemfile.lock

Lines changed: 0 additions & 218 deletions
This file was deleted.

containers/ruby-2-rails-5/test-project/README.md

Lines changed: 0 additions & 24 deletions
This file was deleted.

containers/ruby-2-rails-5/test-project/Rakefile

Lines changed: 0 additions & 6 deletions
This file was deleted.

containers/ruby-2-rails-5/test-project/app/assets/config/manifest.js

Lines changed: 0 additions & 3 deletions
This file was deleted.

0 commit comments

Comments
 (0)