Ming Wang commited on
Commit
1c5dd60
·
1 Parent(s): faf07a1

chore: auto-create branch on Codespace + protect main

Browse files
Files changed (1) hide show
  1. .devcontainer/devcontainer.json +4 -1
.devcontainer/devcontainer.json CHANGED
@@ -11,6 +11,7 @@
11
  "memory": "8gb"
12
  },
13
  "updateContentCommand": "npm install -g @angular/cli && cd frontend && npm ci --prefer-offline --no-audit && cd ../backend && npm ci --prefer-offline --no-audit || true",
 
14
  "postStartCommand": "cd /workspaces/Zero-friction && git pull origin main && cd frontend && npm ci --prefer-offline --no-audit && cd ../backend && npm ci --prefer-offline --no-audit || true",
15
  "customizations": {
16
  "vscode": {
@@ -21,7 +22,9 @@
21
  "dbaeumer.vscode-eslint"
22
  ],
23
  "settings": {
24
- "terminal.integrated.defaultProfile.linux": "zsh"
 
 
25
  }
26
  }
27
  }
 
11
  "memory": "8gb"
12
  },
13
  "updateContentCommand": "npm install -g @angular/cli && cd frontend && npm ci --prefer-offline --no-audit && cd ../backend && npm ci --prefer-offline --no-audit || true",
14
+ "postCreateCommand": "git checkout -b feat/$(echo $GITHUB_USER)-$(date +%Y%m%d-%H%M%S)",
15
  "postStartCommand": "cd /workspaces/Zero-friction && git pull origin main && cd frontend && npm ci --prefer-offline --no-audit && cd ../backend && npm ci --prefer-offline --no-audit || true",
16
  "customizations": {
17
  "vscode": {
 
22
  "dbaeumer.vscode-eslint"
23
  ],
24
  "settings": {
25
+ "terminal.integrated.defaultProfile.linux": "zsh",
26
+ "git.branchProtection": ["main"],
27
+ "git.branchProtectionPrompt": "alwaysCommitToNewBranch"
28
  }
29
  }
30
  }