vsc-sync
v0.1.0
Published
CLI to share ".vscode/settings.json"
Maintainers
Readme
vsc-sync
vsc-sync is a CLI tool designed to share .vscode/settings.json within a development team.
It allows teams to establish and maintain a set of common settings, while also providing the flexibility for individual team members to override these settings according to their preferences.
Installation
npm install -D vsc-syncUsage
Initialization
vsc-sync init- Adds the following to
.gitignore:.vscode/settings.json .vscode/settings-local.jsonc - If
.vscode/settings.jsonexists, copies it to.vscode/settings-project.jsonc. - Creates an empty
.vscode/settings-local.jsoncif it doesn't exist.
Synchronization
vsc-sync sync- Merges
.vscode/settings-project.jsoncand.vscode/settings-local.jsoncto create.vscode/settings.json. - It's recommended to run this command with a Git post-checkout hook.
Git Hook Setup
npm install husky --save-dev
npx husky init.husky/post-checkout
npx vsc-sync synclefthook.yml
post-checkout:
jobs:
name: sync vscode settings
run: npx vsc-sync syncnpm install lefthook --save-dev
npx lefthook install