From f392683a6bbd2c91be702339083aa6dd8f549746 Mon Sep 17 00:00:00 2001 From: Matt Wilson Date: Tue, 15 Sep 2026 05:13:55 +1000 Subject: [PATCH 1/7] docs(misc-dev-scripts): Phase 0 ownership and templates/ catalogue scaffold Declare project-drop-in ownership; add templates/{editorconfig,gitattributes, gitignore,vimrc,vscode}// layout with READMEs; bump to 0.5.2. --- CHANGES.md | 9 ++ NEWS.md | 1 + README.md | 63 ++++++++++++- TODO.md | 5 ++ VERSION | 2 +- templates/README.md | 97 +++++++++++++++++++++ templates/editorconfig/README.md | 41 +++++++++ templates/editorconfig/c#/.gitkeep | 0 templates/editorconfig/c/.gitkeep | 0 templates/editorconfig/c_cxx/.gitkeep | 0 templates/editorconfig/cxx/.gitkeep | 0 templates/editorconfig/generic/.gitkeep | 0 templates/editorconfig/go/.gitkeep | 0 templates/editorconfig/javascript/.gitkeep | 0 templates/editorconfig/python/.gitkeep | 0 templates/editorconfig/ruby/.gitkeep | 0 templates/editorconfig/rust/.gitkeep | 0 templates/editorconfig/zig/.gitkeep | 0 templates/gitattributes/README.md | 41 +++++++++ templates/gitattributes/c#/.gitkeep | 0 templates/gitattributes/c/.gitkeep | 0 templates/gitattributes/c_cxx/.gitkeep | 0 templates/gitattributes/cxx/.gitkeep | 0 templates/gitattributes/generic/.gitkeep | 0 templates/gitattributes/go/.gitkeep | 0 templates/gitattributes/javascript/.gitkeep | 0 templates/gitattributes/python/.gitkeep | 0 templates/gitattributes/ruby/.gitkeep | 0 templates/gitattributes/rust/.gitkeep | 0 templates/gitattributes/zig/.gitkeep | 0 templates/gitignore/README.md | 41 +++++++++ templates/gitignore/c#/.gitkeep | 0 templates/gitignore/c/.gitkeep | 0 templates/gitignore/c_cxx/.gitkeep | 0 templates/gitignore/cxx/.gitkeep | 0 templates/gitignore/generic/.gitkeep | 0 templates/gitignore/go/.gitkeep | 0 templates/gitignore/javascript/.gitkeep | 0 templates/gitignore/python/.gitkeep | 0 templates/gitignore/ruby/.gitkeep | 0 templates/gitignore/rust/.gitkeep | 0 templates/gitignore/zig/.gitkeep | 0 templates/vimrc/README.md | 41 +++++++++ templates/vimrc/c#/.gitkeep | 0 templates/vimrc/c/.gitkeep | 0 templates/vimrc/c_cxx/.gitkeep | 0 templates/vimrc/cxx/.gitkeep | 0 templates/vimrc/generic/.gitkeep | 0 templates/vimrc/go/.gitkeep | 0 templates/vimrc/javascript/.gitkeep | 0 templates/vimrc/python/.gitkeep | 0 templates/vimrc/ruby/.gitkeep | 0 templates/vimrc/rust/.gitkeep | 0 templates/vimrc/zig/.gitkeep | 0 templates/vscode/README.md | 41 +++++++++ templates/vscode/c#/.gitkeep | 0 templates/vscode/c/.gitkeep | 0 templates/vscode/c_cxx/.gitkeep | 0 templates/vscode/cxx/.gitkeep | 0 templates/vscode/generic/.gitkeep | 0 templates/vscode/go/.gitkeep | 0 templates/vscode/javascript/.gitkeep | 0 templates/vscode/python/.gitkeep | 0 templates/vscode/ruby/.gitkeep | 0 templates/vscode/rust/.gitkeep | 0 templates/vscode/zig/.gitkeep | 0 66 files changed, 377 insertions(+), 5 deletions(-) create mode 100644 templates/README.md create mode 100644 templates/editorconfig/README.md create mode 100644 templates/editorconfig/c#/.gitkeep create mode 100644 templates/editorconfig/c/.gitkeep create mode 100644 templates/editorconfig/c_cxx/.gitkeep create mode 100644 templates/editorconfig/cxx/.gitkeep create mode 100644 templates/editorconfig/generic/.gitkeep create mode 100644 templates/editorconfig/go/.gitkeep create mode 100644 templates/editorconfig/javascript/.gitkeep create mode 100644 templates/editorconfig/python/.gitkeep create mode 100644 templates/editorconfig/ruby/.gitkeep create mode 100644 templates/editorconfig/rust/.gitkeep create mode 100644 templates/editorconfig/zig/.gitkeep create mode 100644 templates/gitattributes/README.md create mode 100644 templates/gitattributes/c#/.gitkeep create mode 100644 templates/gitattributes/c/.gitkeep create mode 100644 templates/gitattributes/c_cxx/.gitkeep create mode 100644 templates/gitattributes/cxx/.gitkeep create mode 100644 templates/gitattributes/generic/.gitkeep create mode 100644 templates/gitattributes/go/.gitkeep create mode 100644 templates/gitattributes/javascript/.gitkeep create mode 100644 templates/gitattributes/python/.gitkeep create mode 100644 templates/gitattributes/ruby/.gitkeep create mode 100644 templates/gitattributes/rust/.gitkeep create mode 100644 templates/gitattributes/zig/.gitkeep create mode 100644 templates/gitignore/README.md create mode 100644 templates/gitignore/c#/.gitkeep create mode 100644 templates/gitignore/c/.gitkeep create mode 100644 templates/gitignore/c_cxx/.gitkeep create mode 100644 templates/gitignore/cxx/.gitkeep create mode 100644 templates/gitignore/generic/.gitkeep create mode 100644 templates/gitignore/go/.gitkeep create mode 100644 templates/gitignore/javascript/.gitkeep create mode 100644 templates/gitignore/python/.gitkeep create mode 100644 templates/gitignore/ruby/.gitkeep create mode 100644 templates/gitignore/rust/.gitkeep create mode 100644 templates/gitignore/zig/.gitkeep create mode 100644 templates/vimrc/README.md create mode 100644 templates/vimrc/c#/.gitkeep create mode 100644 templates/vimrc/c/.gitkeep create mode 100644 templates/vimrc/c_cxx/.gitkeep create mode 100644 templates/vimrc/cxx/.gitkeep create mode 100644 templates/vimrc/generic/.gitkeep create mode 100644 templates/vimrc/go/.gitkeep create mode 100644 templates/vimrc/javascript/.gitkeep create mode 100644 templates/vimrc/python/.gitkeep create mode 100644 templates/vimrc/ruby/.gitkeep create mode 100644 templates/vimrc/rust/.gitkeep create mode 100644 templates/vimrc/zig/.gitkeep create mode 100644 templates/vscode/README.md create mode 100644 templates/vscode/c#/.gitkeep create mode 100644 templates/vscode/c/.gitkeep create mode 100644 templates/vscode/c_cxx/.gitkeep create mode 100644 templates/vscode/cxx/.gitkeep create mode 100644 templates/vscode/generic/.gitkeep create mode 100644 templates/vscode/go/.gitkeep create mode 100644 templates/vscode/javascript/.gitkeep create mode 100644 templates/vscode/python/.gitkeep create mode 100644 templates/vscode/ruby/.gitkeep create mode 100644 templates/vscode/rust/.gitkeep create mode 100644 templates/vscode/zig/.gitkeep diff --git a/CHANGES.md b/CHANGES.md index ba33365..2d4d2a7 100644 --- a/CHANGES.md +++ b/CHANGES.md @@ -3,6 +3,7 @@ ## Table of Contents +- [0.5.2 - 15th September 2026](#052---15th-september-2026) - [0.5.1 - 14th September 2026](#051---14th-september-2026) - [0.5.0 - 1st September 2026](#050---1st-september-2026) - [0.4.2 - 25th August 2026](#042---25th-august-2026) @@ -13,6 +14,14 @@ - [0.1.1 - 11th August 2026](#011---11th-august-2026) +## 0.5.2 - 15th September 2026 + +* Declared Phase 0 ownership with **misc-config-scripts**: this repo owns language-specific project drop-ins and **`run_all_unit_tests`**; sibling keeps **`.commonrc`** / **`.gitconfig`** only after cutover; +* Scaffolded **templates/** catalogue layout (`editorconfig`, `gitattributes`, `gitignore`, `vimrc`, `vscode` × language keys; **`.gitkeep`** placeholders); +* Added **templates/README.md** and per-family READMEs (status, copy destinations, migration notes); +* Updated **README.md** (ownership table; catalogue layout; templates section); + + ## 0.5.1 - 14th September 2026 * **shell-scripts/run_all_unit_tests/python/run_all_unit_tests.sh**: diff --git a/NEWS.md b/NEWS.md index 4f8358b..34f9a77 100644 --- a/NEWS.md +++ b/NEWS.md @@ -3,6 +3,7 @@ | Date | News Item | Details | | -------------------- | --------- | ------- | +| 15th September 2026 | [**misc-dev-scripts** 0.5.2](https://github.com/synesissoftware/misc-dev-scripts/releases/tag/0.5.2) released | Phase 0 ownership; `templates/` scaffold | | 14th September 2026 | [**misc-dev-scripts** 0.5.1](https://github.com/synesissoftware/misc-dev-scripts/releases/tag/0.5.1) released | Python `.sis` help + prefer project `.venv` | | 1st September 2026 | [**misc-dev-scripts** 0.5.0](https://github.com/synesissoftware/misc-dev-scripts/releases/tag/0.5.0) released | JavaScript `run_all_unit_tests` runner | | 25th August 2026 | [**misc-dev-scripts** 0.4.2](https://github.com/synesissoftware/misc-dev-scripts/releases/tag/0.4.2) released | Ruby `tput` TERM/TTY guard | diff --git a/README.md b/README.md index 26f07d9..cdc4de8 100644 --- a/README.md +++ b/README.md @@ -1,9 +1,11 @@ # misc-dev-scripts + Miscellaneous Development Scripts ![Language](https://img.shields.io/badge/language-Bash-blue.svg) [![License](https://img.shields.io/badge/License-BSD_3--Clause-blue.svg)](https://opensource.org/licenses/BSD-3-Clause) +[![Version](https://img.shields.io/badge/version-0.5.2-blue.svg)](https://github.com/synesissoftware/misc-dev-scripts/blob/master/CHANGES.md) [![Last Commit](https://img.shields.io/github/last-commit/synesissoftware/misc-dev-scripts)](https://github.com/synesissoftware/misc-dev-scripts/commits/master) [![CI](https://github.com/synesissoftware/misc-dev-scripts/actions/workflows/ci.yml/badge.svg)](https://github.com/synesissoftware/misc-dev-scripts/actions/workflows/ci.yml) @@ -11,19 +13,58 @@ Miscellaneous Development Scripts ## Table of Contents - [Introduction](#introduction) +- [Ownership and migration (Phase 0)](#ownership-and-migration-phase-0) +- [Catalogue layout](#catalogue-layout) - [Shell Scripts](#shell-scripts) - [run\_all\_unit\_tests.sh](#run_all_unit_testssh) +- [Project drop-in templates](#project-drop-in-templates) - [Related projects](#related-projects) - [Project Information](#project-information) ## Introduction -**misc-dev-scripts** is a small catalog of shell helpers intended to be **copied** into Synesis (and related) language libraries — principally **run_all_unit_tests.sh** variants for **JavaScript**, **Python**, and **Ruby** today, with further languages planned. +**misc-dev-scripts** is a catalog of resources intended to be **copied** into Synesis (and related) **project** trees: shell helpers (under **shell-scripts/**) and language-specific project drop-in templates (under **templates/**). + +Today the shipped helpers are principally **run_all_unit_tests.sh** variants for **JavaScript**, **Python**, and **Ruby**, with further languages and template families planned. When updating a consumer, cite this repository’s **VERSION** in that project’s **CHANGES.md**. + +Sibling project: [**misc-config-scripts**](https://github.com/synesissoftware/misc-config-scripts) (**`.commonrc`** and **`.gitconfig`** only after cutover). + + +## Ownership and migration (Phase 0) + +**Status: intent declared — layout scaffolded; content cutover not complete.** + +Distinguish **self** boilerplate (this repository’s own root editor/Git files) from **templates** (copied into other projects). + +| Kind | **misc-config-scripts** | This repo | +| --- | --- | --- | +| **Self** **`.editorconfig`**, **`.gitattributes`**, **`.gitignore`**, **`.vimrc`**, **`.vscode/settings.json`** | ✅ | ✅ | +| **Templates:** **`.gitconfig`**, **`.commonrc`** | ✅ only | ❌ | +| **Templates:** language-specific **`run_all_unit_tests.sh`**, **`.editorconfig`**, **`.gitattributes`**, **`.gitignore`**, **`.vimrc`**, **`.vscode/settings.json`** | ❌ (legacy frozen) | ✅ only | + +Until later phases populate **`templates/`**, continue copying VS Code settings and **`.gitattributes`** from **misc-config-scripts** (legacy catalogs). Do **not** add new language templates there. -Canonical copies live under **shell-scripts/**; consuming projects keep a root-level **run_all_unit_tests.sh**. When updating a consumer, cite this repository’s **VERSION** in that project’s **CHANGES.md**. -Sibling project: [**misc-config-scripts**](https://github.com/synesissoftware/misc-config-scripts) (shell rc, Git, and editor/attribute templates). +## Catalogue layout + +Agreed paths (Phase 0): + +```text +misc-dev-scripts/ + shell-scripts/ + run_all_unit_tests//run_all_unit_tests.sh + templates/ + editorconfig//.editorconfig + gitattributes//.gitattributes + gitignore//.gitignore + vimrc//.vimrc + vscode//settings.json +``` + +Language keys (lexicographic): **c**, **c#**, **c_cxx**, **cxx**, **generic**, **go**, **javascript**, **python**, **ruby**, **rust**, **zig**. + +See [**templates/README.md**](./templates/README.md) for status, ownership detail, and copy destinations. ## Shell Scripts @@ -42,9 +83,22 @@ Language variants: Use `--help` on any variant for the authoritative flag list. +## Project drop-in templates + +See [**templates/README.md**](./templates/README.md). Families: + +* [**editorconfig**](./templates/editorconfig/README.md); +* [**gitattributes**](./templates/gitattributes/README.md); +* [**gitignore**](./templates/gitignore/README.md); +* [**vimrc**](./templates/vimrc/README.md); +* [**vscode**](./templates/vscode/README.md); + +**Phase 0:** directories reserved (**`.gitkeep`**); not ready to copy. + + ## Related projects -A peer-project that provides configuration resources is [**misc-config-scripts**](https://github.com/synesissoftware/misc-config-scripts). +A peer project that provides **`.commonrc`** and **`.gitconfig`** (and, until cutover, legacy project settings / gitattributes catalogs) is [**misc-config-scripts**](https://github.com/synesissoftware/misc-config-scripts). Resources from this project are used in the following projects (case-insensitive lexicographic order): @@ -70,6 +124,7 @@ Resources from this project are used in the following projects (case-insensitive * **VERSION** — see [**VERSION**](./VERSION); * **CHANGES** — see [**CHANGES.md**](./CHANGES.md); +* **NEWS** — see [**NEWS.md**](./NEWS.md); * **TODO** — see [**TODO.md**](./TODO.md); * **License** — BSD-3-Clause; see [**LICENSE**](./LICENSE); diff --git a/TODO.md b/TODO.md index b6a5090..e83dc72 100644 --- a/TODO.md +++ b/TODO.md @@ -88,6 +88,11 @@ * [x] Replace **.vscode/settings.json** with **misc-config-scripts** `settings.json/generic/settings.json` (multi-language union; not a hand-slimmed subset); * [x] Align **LICENSE** year range with current year; * [x] Add nested **shell-scripts/run_all_unit_tests/README.md** (copy command, per-lang paths, layout contracts, flag table); +* [x] ~~~Phase 0: declare ownership; scaffold **templates/** catalogue layout + READMEs~~~ - ✅; +* [ ] Phase 1: complete **self** boilerplate (**`.editorconfig`**; retarget root **`.vimrc`** as self for this Bash catalog, not C/C++ consumer gold); +* [ ] Phase 2: populate **templates/** from freelibs exemplars and migrate **misc-config-scripts** `settings.json/` + `gitattributes/` content; +* [ ] Phase 4: refresh this repo’s self **`.vscode/settings.json`** (and related self files) from **templates/vscode/generic/** (or shell-appropriate) once populated; +* [ ] Later: hoist **build_dist.sh** / **build_dist_uv.sh** (Python), **build_gem.sh** (Ruby), **rustfmt.toml** / **scripts/fmt** (Rust), Go **build.sh** / runners, and further common helpers under **shell-scripts/** or **templates/** as appropriate; * [ ] Optional: sample bootstrap notes for copy-vs-sync adoption; * [ ] Distribution / drift control: `SCRIPT_VERSION` header matching **VERSION**; document consumer CHANGES citation convention; optional sync helper; optional `testdata/` CI fixtures; diff --git a/VERSION b/VERSION index 4b9fcbe..cb0c939 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -0.5.1 +0.5.2 diff --git a/templates/README.md b/templates/README.md new file mode 100644 index 0000000..edc076c --- /dev/null +++ b/templates/README.md @@ -0,0 +1,97 @@ +# Project drop-in templates + + +Language-specific **project** drop-in templates for Synesis (and related) libraries. + +This tree is the **canonical catalogue layout** for project-local config files that consumers copy into a repository root (or **`.vscode/`**). Content is staged here in phases; until a language directory holds a real template file, a **`.gitkeep`** marks the reserved path. + + +## Table of Contents + +- [Status](#status) +- [Self boilerplate vs templates](#self-boilerplate-vs-templates) +- [Ownership](#ownership) +- [Layout](#layout) +- [Language keys](#language-keys) +- [How to use (once populated)](#how-to-use-once-populated) +- [Related](#related) + + +## Status + +**Phase 0 (layout declared):** directory tree and documentation only. Do **not** treat empty language folders as ready to copy. Population and cutover from **misc-config-scripts** are later phases. + + +## Self boilerplate vs templates + +| Kind | Where | Purpose | +| --- | --- | --- | +| **Self** | Repository root (e.g. this project's own **`.vimrc`**, **`.gitignore`**) | Configures *this* repository | +| **Template** | Under **`templates///`** | Copied into *other* projects | + +Do not confuse root self files with the catalogue under **`templates/`**. + + +## Ownership + +| Template family | Canonical home | Notes | +| --- | --- | --- | +| **.editorconfig** | **misc-dev-scripts** `templates/editorconfig/` | Intent; content TBD | +| **.gitattributes** | **misc-dev-scripts** `templates/gitattributes/` | Today still shipped from **misc-config-scripts** `gitattributes/` (deprecated for new work) | +| **.gitignore** | **misc-dev-scripts** `templates/gitignore/` | Intent; content TBD | +| **.vimrc** | **misc-dev-scripts** `templates/vimrc/` | Intent; content TBD | +| **.vscode** (`settings.json`) | **misc-dev-scripts** `templates/vscode/` | Today still shipped from **misc-config-scripts** `settings.json/` (deprecated for new work) | +| **run_all_unit_tests.sh** | **misc-dev-scripts** `shell-scripts/run_all_unit_tests/` | Already canonical | +| **.gitconfig** / **.commonrc** | **misc-config-scripts** only | Machine / shell environment — not project drop-ins | + + +## Layout + +| Path | Consumer destination | +| --- | --- | +| **editorconfig/\/.editorconfig** | **`.editorconfig`** | +| **gitattributes/\/.gitattributes** | **`.gitattributes`** | +| **gitignore/\/.gitignore** | **`.gitignore`** | +| **vimrc/\/.vimrc** | **`.vimrc`** | +| **vscode/\/settings.json** | **`.vscode/settings.json`** | + +Shell helpers remain under **`shell-scripts/`** (not under **`templates/`**). + + +## Language keys + +Lexicographic language directory names (same set for every family): + +* **c**; +* **c#**; +* **c_cxx** (mixed C / C++); +* **cxx**; +* **generic** (union / mixed-language trees); +* **go**; +* **javascript**; +* **python**; +* **ruby**; +* **rust**; +* **zig**. + + +## How to use (once populated) + +```sh +cp templates/vscode/python/settings.json /path/to/repo/.vscode/settings.json +``` + +```sh +cp templates/gitattributes/go/.gitattributes /path/to/repo/.gitattributes +``` + +When updating a consumer, cite this repository’s **VERSION** in that project’s **CHANGES.md**. + + +## Related + +* [**shell-scripts/run_all_unit_tests/README.md**](../shell-scripts/run_all_unit_tests/README.md) — test-runner helpers; +* Sibling [**misc-config-scripts**](https://github.com/synesissoftware/misc-config-scripts) — **`.gitconfig`** and **`.commonrc`** only (after cutover); project dotfile catalogs there are frozen pending migration. + + + diff --git a/templates/editorconfig/README.md b/templates/editorconfig/README.md new file mode 100644 index 0000000..cf88c04 --- /dev/null +++ b/templates/editorconfig/README.md @@ -0,0 +1,41 @@ +# `.editorconfig` templates + + +Drop-in root **`.editorconfig`** files, organised by primary language. + +**Status:** Phase 0 — layout only (**`.gitkeep`** placeholders). Content lands in a later phase. + + +## Table of Contents + +- [How to use (once populated)](#how-to-use-once-populated) +- [Layout](#layout) + + +## How to use (once populated) + +```sh +cp templates/editorconfig//.editorconfig /path/to/repo/.editorconfig +``` + +Prefer the language-specific template that matches the project’s primary language; use **generic** only for multi-language trees. + + +## Layout + +| Path | Role | +| --- | --- | +| **c/** | C-primary | +| **c#/** | C# / .NET | +| **c_cxx/** | Mixed C / C++ | +| **cxx/** | C++-primary | +| **generic/** | Union / mixed | +| **go/** | Go | +| **javascript/** | JavaScript / TypeScript | +| **python/** | Python | +| **ruby/** | Ruby | +| **rust/** | Rust | +| **zig/** | Zig | + + + diff --git a/templates/editorconfig/c#/.gitkeep b/templates/editorconfig/c#/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/templates/editorconfig/c/.gitkeep b/templates/editorconfig/c/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/templates/editorconfig/c_cxx/.gitkeep b/templates/editorconfig/c_cxx/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/templates/editorconfig/cxx/.gitkeep b/templates/editorconfig/cxx/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/templates/editorconfig/generic/.gitkeep b/templates/editorconfig/generic/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/templates/editorconfig/go/.gitkeep b/templates/editorconfig/go/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/templates/editorconfig/javascript/.gitkeep b/templates/editorconfig/javascript/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/templates/editorconfig/python/.gitkeep b/templates/editorconfig/python/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/templates/editorconfig/ruby/.gitkeep b/templates/editorconfig/ruby/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/templates/editorconfig/rust/.gitkeep b/templates/editorconfig/rust/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/templates/editorconfig/zig/.gitkeep b/templates/editorconfig/zig/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/templates/gitattributes/README.md b/templates/gitattributes/README.md new file mode 100644 index 0000000..0a0f324 --- /dev/null +++ b/templates/gitattributes/README.md @@ -0,0 +1,41 @@ +# `.gitattributes` templates + + +Drop-in root **`.gitattributes`** files, organised by primary language. + +**Status:** Phase 0 — layout only (**`.gitkeep`** placeholders). Until cutover, copy from **misc-config-scripts** `gitattributes/` (frozen: no new language templates there). Content will be migrated here in a later phase. + + +## Table of Contents + +- [How to use (once populated)](#how-to-use-once-populated) +- [Layout](#layout) + + +## How to use (once populated) + +```sh +cp templates/gitattributes//.gitattributes /path/to/repo/.gitattributes +``` + +Prefer the language-specific template that matches the project’s primary language; use **generic** only for multi-language trees. Use **c_cxx** for mixed native C / C++ trees. + + +## Layout + +| Path | Role | +| --- | --- | +| **c/** | C-primary | +| **c#/** | C# / .NET | +| **c_cxx/** | Mixed C / C++ | +| **cxx/** | C++-primary | +| **generic/** | Union / mixed | +| **go/** | Go | +| **javascript/** | JavaScript / TypeScript | +| **python/** | Python | +| **ruby/** | Ruby | +| **rust/** | Rust | +| **zig/** | Zig | + + + diff --git a/templates/gitattributes/c#/.gitkeep b/templates/gitattributes/c#/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/templates/gitattributes/c/.gitkeep b/templates/gitattributes/c/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/templates/gitattributes/c_cxx/.gitkeep b/templates/gitattributes/c_cxx/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/templates/gitattributes/cxx/.gitkeep b/templates/gitattributes/cxx/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/templates/gitattributes/generic/.gitkeep b/templates/gitattributes/generic/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/templates/gitattributes/go/.gitkeep b/templates/gitattributes/go/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/templates/gitattributes/javascript/.gitkeep b/templates/gitattributes/javascript/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/templates/gitattributes/python/.gitkeep b/templates/gitattributes/python/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/templates/gitattributes/ruby/.gitkeep b/templates/gitattributes/ruby/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/templates/gitattributes/rust/.gitkeep b/templates/gitattributes/rust/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/templates/gitattributes/zig/.gitkeep b/templates/gitattributes/zig/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/templates/gitignore/README.md b/templates/gitignore/README.md new file mode 100644 index 0000000..5687149 --- /dev/null +++ b/templates/gitignore/README.md @@ -0,0 +1,41 @@ +# `.gitignore` templates + + +Drop-in root **`.gitignore`** files, organised by primary language. + +**Status:** Phase 0 — layout only (**`.gitkeep`** placeholders). Content lands in a later phase. + + +## Table of Contents + +- [How to use (once populated)](#how-to-use-once-populated) +- [Layout](#layout) + + +## How to use (once populated) + +```sh +cp templates/gitignore//.gitignore /path/to/repo/.gitignore +``` + +Prefer the language-specific template that matches the project’s primary language; use **generic** only for multi-language trees. + + +## Layout + +| Path | Role | +| --- | --- | +| **c/** | C-primary | +| **c#/** | C# / .NET | +| **c_cxx/** | Mixed C / C++ | +| **cxx/** | C++-primary | +| **generic/** | Union / mixed | +| **go/** | Go | +| **javascript/** | JavaScript / TypeScript | +| **python/** | Python | +| **ruby/** | Ruby | +| **rust/** | Rust | +| **zig/** | Zig | + + + diff --git a/templates/gitignore/c#/.gitkeep b/templates/gitignore/c#/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/templates/gitignore/c/.gitkeep b/templates/gitignore/c/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/templates/gitignore/c_cxx/.gitkeep b/templates/gitignore/c_cxx/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/templates/gitignore/cxx/.gitkeep b/templates/gitignore/cxx/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/templates/gitignore/generic/.gitkeep b/templates/gitignore/generic/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/templates/gitignore/go/.gitkeep b/templates/gitignore/go/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/templates/gitignore/javascript/.gitkeep b/templates/gitignore/javascript/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/templates/gitignore/python/.gitkeep b/templates/gitignore/python/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/templates/gitignore/ruby/.gitkeep b/templates/gitignore/ruby/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/templates/gitignore/rust/.gitkeep b/templates/gitignore/rust/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/templates/gitignore/zig/.gitkeep b/templates/gitignore/zig/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/templates/vimrc/README.md b/templates/vimrc/README.md new file mode 100644 index 0000000..e33c7b7 --- /dev/null +++ b/templates/vimrc/README.md @@ -0,0 +1,41 @@ +# `.vimrc` templates + + +Drop-in root **`.vimrc`** files, organised by primary language. + +**Status:** Phase 0 — layout only (**`.gitkeep`** placeholders). Content lands in a later phase (lifted from freelibs exemplars). Do **not** treat this repository’s root **`.vimrc`** as the consumer template — that file is **self** boilerplate for **misc-dev-scripts**. + + +## Table of Contents + +- [How to use (once populated)](#how-to-use-once-populated) +- [Layout](#layout) + + +## How to use (once populated) + +```sh +cp templates/vimrc//.vimrc /path/to/repo/.vimrc +``` + +Prefer the language-specific template that matches the project’s primary language; use **generic** only for multi-language trees. + + +## Layout + +| Path | Role | +| --- | --- | +| **c/** | C-primary | +| **c#/** | C# / .NET | +| **c_cxx/** | Mixed C / C++ | +| **cxx/** | C++-primary | +| **generic/** | Union / mixed | +| **go/** | Go | +| **javascript/** | JavaScript / TypeScript | +| **python/** | Python | +| **ruby/** | Ruby | +| **rust/** | Rust | +| **zig/** | Zig | + + + diff --git a/templates/vimrc/c#/.gitkeep b/templates/vimrc/c#/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/templates/vimrc/c/.gitkeep b/templates/vimrc/c/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/templates/vimrc/c_cxx/.gitkeep b/templates/vimrc/c_cxx/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/templates/vimrc/cxx/.gitkeep b/templates/vimrc/cxx/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/templates/vimrc/generic/.gitkeep b/templates/vimrc/generic/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/templates/vimrc/go/.gitkeep b/templates/vimrc/go/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/templates/vimrc/javascript/.gitkeep b/templates/vimrc/javascript/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/templates/vimrc/python/.gitkeep b/templates/vimrc/python/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/templates/vimrc/ruby/.gitkeep b/templates/vimrc/ruby/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/templates/vimrc/rust/.gitkeep b/templates/vimrc/rust/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/templates/vimrc/zig/.gitkeep b/templates/vimrc/zig/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/templates/vscode/README.md b/templates/vscode/README.md new file mode 100644 index 0000000..12548b7 --- /dev/null +++ b/templates/vscode/README.md @@ -0,0 +1,41 @@ +# VS Code `settings.json` templates + + +Drop-in workspace **`.vscode/settings.json`** files, organised by primary language. + +**Status:** Phase 0 — layout only (**`.gitkeep`** placeholders). Until cutover, copy from **misc-config-scripts** `settings.json/` (frozen: no new language templates there). Content will be migrated here in a later phase as **`templates/vscode//settings.json`**. + + +## Table of Contents + +- [How to use (once populated)](#how-to-use-once-populated) +- [Layout](#layout) + + +## How to use (once populated) + +```sh +cp templates/vscode//settings.json /path/to/repo/.vscode/settings.json +``` + +Prefer the language-specific template that matches the project’s primary language; use **generic** only for multi-language trees. Use **c_cxx** when a mixed native C / C++ settings union is provided. + + +## Layout + +| Path | Role | +| --- | --- | +| **c/** | C-primary | +| **c#/** | C# / .NET | +| **c_cxx/** | Mixed C / C++ | +| **cxx/** | C++-primary | +| **generic/** | Union / mixed | +| **go/** | Go | +| **javascript/** | JavaScript / TypeScript | +| **python/** | Python | +| **ruby/** | Ruby | +| **rust/** | Rust | +| **zig/** | Zig | + + + diff --git a/templates/vscode/c#/.gitkeep b/templates/vscode/c#/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/templates/vscode/c/.gitkeep b/templates/vscode/c/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/templates/vscode/c_cxx/.gitkeep b/templates/vscode/c_cxx/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/templates/vscode/cxx/.gitkeep b/templates/vscode/cxx/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/templates/vscode/generic/.gitkeep b/templates/vscode/generic/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/templates/vscode/go/.gitkeep b/templates/vscode/go/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/templates/vscode/javascript/.gitkeep b/templates/vscode/javascript/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/templates/vscode/python/.gitkeep b/templates/vscode/python/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/templates/vscode/ruby/.gitkeep b/templates/vscode/ruby/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/templates/vscode/rust/.gitkeep b/templates/vscode/rust/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/templates/vscode/zig/.gitkeep b/templates/vscode/zig/.gitkeep new file mode 100644 index 0000000..e69de29 From 838df2a2d57989314ecef950bfbadd44c900d9aa Mon Sep 17 00:00:00 2001 From: Matt Wilson Date: Tue, 15 Sep 2026 08:31:03 +1000 Subject: [PATCH 2/7] chore(misc-dev-scripts): Phase 1 self boilerplate and c_cxx vimrc seed Add shell/docs .editorconfig; retarget root .vimrc; preserve former C/C++ gold as templates/vimrc/c_cxx/.vimrc; bump to 0.5.3. --- .editorconfig | 44 +++++++++++++++++++++ .vimrc | 39 ++++++------------- CHANGES.md | 11 ++++++ NEWS.md | 1 + README.md | 6 +-- TODO.md | 2 +- VERSION | 2 +- templates/README.md | 2 +- templates/vimrc/README.md | 6 +-- templates/vimrc/c_cxx/.gitkeep | 0 templates/vimrc/c_cxx/.vimrc | 70 ++++++++++++++++++++++++++++++++++ 11 files changed, 147 insertions(+), 36 deletions(-) create mode 100644 .editorconfig delete mode 100644 templates/vimrc/c_cxx/.gitkeep create mode 100644 templates/vimrc/c_cxx/.vimrc diff --git a/.editorconfig b/.editorconfig new file mode 100644 index 0000000..c3a7477 --- /dev/null +++ b/.editorconfig @@ -0,0 +1,44 @@ +root = true + +# Self boilerplate for this shell / docs catalog. +# Language indent/EOL/charset overlap with .vscode/settings.json. +# Rulers, renderWhitespace, detectIndentation, and mergeEditor cannot be +# expressed here — they stay in settings.json. + +[*] +charset = utf-8 +end_of_line = lf +indent_size = 2 +indent_style = tab +insert_final_newline = true +trim_trailing_whitespace = true + +# [bat] +[*.{bat,cmd}] +end_of_line = crlf +indent_size = 4 +indent_style = space + +# [json] +[*.json] +indent_size = 2 +indent_style = space + +# [markdown] +[*.md] +indent_size = 2 +indent_style = space + +# [shellscript] (and extensionless shell rc drop-ins) +[*.{bash,sh,zsh}] +indent_size = 2 +indent_style = space + +[{.bashrc,.commonrc,.zshrc}] +indent_size = 2 +indent_style = space + +# [yaml] +[*.{yaml,yml}] +indent_size = 2 +indent_style = space diff --git a/.vimrc b/.vimrc index 1bf33a0..1733fc5 100644 --- a/.vimrc +++ b/.vimrc @@ -1,4 +1,5 @@ -" Synesis C/C++ project .vimrc — aligned with .sis/.vscode/c_cxx/settings.json +" Synesis shell / docs project .vimrc — self boilerplate for +" misc-config-scripts / misc-dev-scripts (aligned with .vscode/settings.json) set nocompatible filetype indent plugin on @@ -17,12 +18,12 @@ set fixeol set list set listchars=tab:->,trail:-,extends:>,precedes:<,nbsp:+ -" editor.detectIndentation: false — global defaults (editor.tabSize: 4, insertSpaces: true) +" editor.detectIndentation: false — global defaults (editor.tabSize: 2, insertSpaces: false) set colorcolumn=76 -set expandtab -set shiftwidth=4 -set softtabstop=4 -set tabstop=4 +set noexpandtab +set shiftwidth=2 +set softtabstop=2 +set tabstop=2 " colorcolumn draws a full-column tint in Vim (not a VS Code-style 1px line). " Keep it subtle via the ColorColumn highlight group; reapply after colorscheme changes. @@ -40,31 +41,15 @@ autocmd ColorScheme * call s:ConfigureColorColumn() " files.trimTrailingWhitespace autocmd BufWritePre * %s/\s\+$//e -augroup sis_c_cxx +augroup sis_shell_docs autocmd! - " [c] / [cpp] - autocmd FileType c,cpp setlocal expandtab tabstop=4 shiftwidth=4 softtabstop=4 colorcolumn=60,64,68,72,76 - - " [rust] - autocmd FileType rs setlocal expandtab tabstop=4 shiftwidth=4 softtabstop=4 colorcolumn=76 - - " [cmake] - autocmd FileType cmake setlocal noexpandtab tabstop=4 shiftwidth=4 softtabstop=4 - - " [shellscript] - autocmd FileType sh,bash,zsh setlocal expandtab tabstop=2 shiftwidth=2 softtabstop=2 colorcolumn=60,76 - " [bat] autocmd FileType bat,dosbatch setlocal expandtab tabstop=4 shiftwidth=4 softtabstop=4 colorcolumn=60,76 - " [json] / [markdown] / [yaml] / [ruby] - autocmd FileType json,markdown,yaml,ruby setlocal expandtab tabstop=2 shiftwidth=2 softtabstop=2 - - " [python] - autocmd FileType python setlocal expandtab tabstop=4 shiftwidth=4 softtabstop=4 colorcolumn=60,76 + " [json] / [markdown] / [yaml] + autocmd FileType json,markdown,yaml setlocal expandtab tabstop=2 shiftwidth=2 softtabstop=2 - " [toml] - autocmd FileType toml setlocal noexpandtab tabstop=2 shiftwidth=2 softtabstop=2 + " [shellscript] + autocmd FileType sh,bash,zsh setlocal expandtab tabstop=2 shiftwidth=2 softtabstop=2 colorcolumn=60,76 augroup END - diff --git a/CHANGES.md b/CHANGES.md index 2d4d2a7..f5d7002 100644 --- a/CHANGES.md +++ b/CHANGES.md @@ -3,6 +3,7 @@ ## Table of Contents +- [0.5.3 - 15th September 2026](#053---15th-september-2026) - [0.5.2 - 15th September 2026](#052---15th-september-2026) - [0.5.1 - 14th September 2026](#051---14th-september-2026) - [0.5.0 - 1st September 2026](#050---1st-september-2026) @@ -14,6 +15,16 @@ - [0.1.1 - 11th August 2026](#011---11th-august-2026) +## 0.5.3 - 15th September 2026 + +* Phase 1 self boilerplate: + * added **`.editorconfig`** (shell / docs catalog: UTF-8, LF, shell 2-space, markdown/json/yaml); + * replaced root **`.vimrc`** C/C++ consumer gold with shell / docs **self** **`.vimrc`** (aligned with **`.vscode/settings.json`**); + * preserved former C/C++ gold as **templates/vimrc/c_cxx/.vimrc** for Phase 2; + * confirmed **`.gitattributes`**, **`.gitignore`**, and **`.vscode/settings.json`** remain present as self files; +* Updated **templates/README.md** and **templates/vimrc/README.md** (c_cxx seed note); + + ## 0.5.2 - 15th September 2026 * Declared Phase 0 ownership with **misc-config-scripts**: this repo owns language-specific project drop-ins and **`run_all_unit_tests`**; sibling keeps **`.commonrc`** / **`.gitconfig`** only after cutover; diff --git a/NEWS.md b/NEWS.md index 34f9a77..0704024 100644 --- a/NEWS.md +++ b/NEWS.md @@ -3,6 +3,7 @@ | Date | News Item | Details | | -------------------- | --------- | ------- | +| 15th September 2026 | [**misc-dev-scripts** 0.5.3](https://github.com/synesissoftware/misc-dev-scripts/releases/tag/0.5.3) released | Phase 1 self boilerplate; c_cxx vimrc seed | | 15th September 2026 | [**misc-dev-scripts** 0.5.2](https://github.com/synesissoftware/misc-dev-scripts/releases/tag/0.5.2) released | Phase 0 ownership; `templates/` scaffold | | 14th September 2026 | [**misc-dev-scripts** 0.5.1](https://github.com/synesissoftware/misc-dev-scripts/releases/tag/0.5.1) released | Python `.sis` help + prefer project `.venv` | | 1st September 2026 | [**misc-dev-scripts** 0.5.0](https://github.com/synesissoftware/misc-dev-scripts/releases/tag/0.5.0) released | JavaScript `run_all_unit_tests` runner | diff --git a/README.md b/README.md index cdc4de8..abc1749 100644 --- a/README.md +++ b/README.md @@ -5,7 +5,7 @@ Miscellaneous Development Scripts ![Language](https://img.shields.io/badge/language-Bash-blue.svg) [![License](https://img.shields.io/badge/License-BSD_3--Clause-blue.svg)](https://opensource.org/licenses/BSD-3-Clause) -[![Version](https://img.shields.io/badge/version-0.5.2-blue.svg)](https://github.com/synesissoftware/misc-dev-scripts/blob/master/CHANGES.md) +[![Version](https://img.shields.io/badge/version-0.5.3-blue.svg)](https://github.com/synesissoftware/misc-dev-scripts/blob/master/CHANGES.md) [![Last Commit](https://img.shields.io/github/last-commit/synesissoftware/misc-dev-scripts)](https://github.com/synesissoftware/misc-dev-scripts/commits/master) [![CI](https://github.com/synesissoftware/misc-dev-scripts/actions/workflows/ci.yml/badge.svg)](https://github.com/synesissoftware/misc-dev-scripts/actions/workflows/ci.yml) @@ -33,7 +33,7 @@ Sibling project: [**misc-config-scripts**](https://github.com/synesissoftware/mi ## Ownership and migration (Phase 0) -**Status: intent declared — layout scaffolded; content cutover not complete.** +**Status: Phase 0–1 done for self boilerplate — template content cutover not complete.** Distinguish **self** boilerplate (this repository’s own root editor/Git files) from **templates** (copied into other projects). @@ -93,7 +93,7 @@ See [**templates/README.md**](./templates/README.md). Families: * [**vimrc**](./templates/vimrc/README.md); * [**vscode**](./templates/vscode/README.md); -**Phase 0:** directories reserved (**`.gitkeep`**); not ready to copy. +**Phase 0–1:** directories reserved; **`templates/vimrc/c_cxx/.vimrc`** seeded. Other families not ready to copy. ## Related projects diff --git a/TODO.md b/TODO.md index e83dc72..7e10780 100644 --- a/TODO.md +++ b/TODO.md @@ -89,7 +89,7 @@ * [x] Align **LICENSE** year range with current year; * [x] Add nested **shell-scripts/run_all_unit_tests/README.md** (copy command, per-lang paths, layout contracts, flag table); * [x] ~~~Phase 0: declare ownership; scaffold **templates/** catalogue layout + READMEs~~~ - ✅; -* [ ] Phase 1: complete **self** boilerplate (**`.editorconfig`**; retarget root **`.vimrc`** as self for this Bash catalog, not C/C++ consumer gold); +* [x] ~~~Phase 1: complete **self** boilerplate (**`.editorconfig`**; retarget root **`.vimrc`** as self for this Bash catalog, not C/C++ consumer gold; seed **templates/vimrc/c_cxx/.vimrc**)~~~ - ✅; * [ ] Phase 2: populate **templates/** from freelibs exemplars and migrate **misc-config-scripts** `settings.json/` + `gitattributes/` content; * [ ] Phase 4: refresh this repo’s self **`.vscode/settings.json`** (and related self files) from **templates/vscode/generic/** (or shell-appropriate) once populated; * [ ] Later: hoist **build_dist.sh** / **build_dist_uv.sh** (Python), **build_gem.sh** (Ruby), **rustfmt.toml** / **scripts/fmt** (Rust), Go **build.sh** / runners, and further common helpers under **shell-scripts/** or **templates/** as appropriate; diff --git a/VERSION b/VERSION index cb0c939..be14282 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -0.5.2 +0.5.3 diff --git a/templates/README.md b/templates/README.md index edc076c..822d03e 100644 --- a/templates/README.md +++ b/templates/README.md @@ -19,7 +19,7 @@ This tree is the **canonical catalogue layout** for project-local config files t ## Status -**Phase 0 (layout declared):** directory tree and documentation only. Do **not** treat empty language folders as ready to copy. Population and cutover from **misc-config-scripts** are later phases. +**Phase 0–1:** directory tree and documentation declared; **`templates/vimrc/c_cxx/.vimrc`** seeded (C/C++ gold preserved from former root self files). Other language folders remain empty (**`.gitkeep`**) until Phase 2. Do **not** treat unseeded folders as ready to copy. Cutover from **misc-config-scripts** remains a later phase. ## Self boilerplate vs templates diff --git a/templates/vimrc/README.md b/templates/vimrc/README.md index e33c7b7..2b6ec51 100644 --- a/templates/vimrc/README.md +++ b/templates/vimrc/README.md @@ -3,7 +3,7 @@ Drop-in root **`.vimrc`** files, organised by primary language. -**Status:** Phase 0 — layout only (**`.gitkeep`** placeholders). Content lands in a later phase (lifted from freelibs exemplars). Do **not** treat this repository’s root **`.vimrc`** as the consumer template — that file is **self** boilerplate for **misc-dev-scripts**. +**Status:** Phase 0 layout plus early Phase 1 seed — **`c_cxx/.vimrc`** holds the preserved Synesis C/C++ gold (moved out of this repository’s root self **`.vimrc`**). Other language directories remain **`.gitkeep`** placeholders until Phase 2. Do **not** treat this repository’s root **`.vimrc`** as a consumer template — that file is **self** boilerplate for **misc-dev-scripts**. ## Table of Contents @@ -18,7 +18,7 @@ Drop-in root **`.vimrc`** files, organised by primary language. cp templates/vimrc//.vimrc /path/to/repo/.vimrc ``` -Prefer the language-specific template that matches the project’s primary language; use **generic** only for multi-language trees. +Prefer the language-specific template that matches the project’s primary language; use **generic** only for multi-language trees. Until Phase 2 completes other languages, **`c_cxx`** is the only seeded consumer template here. ## Layout @@ -27,7 +27,7 @@ Prefer the language-specific template that matches the project’s primary langu | --- | --- | | **c/** | C-primary | | **c#/** | C# / .NET | -| **c_cxx/** | Mixed C / C++ | +| **c_cxx/** | Mixed C / C++ (**seeded** — Synesis C/C++ gold) | | **cxx/** | C++-primary | | **generic/** | Union / mixed | | **go/** | Go | diff --git a/templates/vimrc/c_cxx/.gitkeep b/templates/vimrc/c_cxx/.gitkeep deleted file mode 100644 index e69de29..0000000 diff --git a/templates/vimrc/c_cxx/.vimrc b/templates/vimrc/c_cxx/.vimrc new file mode 100644 index 0000000..23ab392 --- /dev/null +++ b/templates/vimrc/c_cxx/.vimrc @@ -0,0 +1,70 @@ +" Synesis C/C++ project .vimrc — aligned with .sis/.vscode/c_cxx/settings.json + +set nocompatible +filetype indent plugin on +syntax enable +set autoindent +set backspace=indent,eol,start +set hlsearch +set incsearch +set number + +" files.insertFinalNewline +set eol +set fixeol + +" editor.renderWhitespace: all +set list +set listchars=tab:->,trail:-,extends:>,precedes:<,nbsp:+ + +" editor.detectIndentation: false — global defaults (editor.tabSize: 4, insertSpaces: true) +set colorcolumn=76 +set expandtab +set shiftwidth=4 +set softtabstop=4 +set tabstop=4 + +" colorcolumn draws a full-column tint in Vim (not a VS Code-style 1px line). +" Keep it subtle via the ColorColumn highlight group; reapply after colorscheme changes. +if has('termguicolors') + " set termguicolors +endif + +function! s:ConfigureColorColumn() abort + highlight ColorColumn ctermbg=236 guibg=#2a2a2a cterm=NONE gui=NONE +endfunction + +call s:ConfigureColorColumn() +autocmd ColorScheme * call s:ConfigureColorColumn() + +" files.trimTrailingWhitespace +autocmd BufWritePre * %s/\s\+$//e + +augroup sis_c_cxx + autocmd! + + " [bat] + autocmd FileType bat,dosbatch setlocal expandtab tabstop=4 shiftwidth=4 softtabstop=4 colorcolumn=60,76 + + " [cmake] + autocmd FileType cmake setlocal noexpandtab tabstop=4 shiftwidth=4 softtabstop=4 + + " [c] / [cpp] + autocmd FileType c,cpp setlocal expandtab tabstop=4 shiftwidth=4 softtabstop=4 colorcolumn=60,64,68,72,76 + + " [json] / [markdown] / [yaml] / [ruby] + autocmd FileType json,markdown,yaml,ruby setlocal expandtab tabstop=2 shiftwidth=2 softtabstop=2 + + " [python] + autocmd FileType python setlocal expandtab tabstop=4 shiftwidth=4 softtabstop=4 colorcolumn=60,76 + + " [rust] + autocmd FileType rs setlocal expandtab tabstop=4 shiftwidth=4 softtabstop=4 colorcolumn=76 + + " [shellscript] + autocmd FileType sh,bash,zsh setlocal expandtab tabstop=2 shiftwidth=2 softtabstop=2 colorcolumn=60,76 + + " [toml] + autocmd FileType toml setlocal noexpandtab tabstop=2 shiftwidth=2 softtabstop=2 +augroup END + From b1296a26dddbc0cb0736c201e58cf9c09b35a7cf Mon Sep 17 00:00:00 2001 From: Matt Wilson Date: Tue, 15 Sep 2026 08:59:37 +1000 Subject: [PATCH 3/7] feat(misc-dev-scripts): Phase 2 populate templates/ project drop-ins Migrate vscode and gitattributes from misc-config-scripts; seed editorconfig, gitignore, and vimrc per language with lex-ordered sections; bump to 0.6.0 as the canonical catalogue. --- CHANGES.md | 14 + NEWS.md | 1 + README.md | 8 +- TODO.md | 2 +- VERSION | 2 +- templates/README.md | 22 +- templates/editorconfig/README.md | 6 +- templates/editorconfig/c#/.editorconfig | 44 +++ templates/editorconfig/c#/.gitkeep | 0 templates/editorconfig/c/.editorconfig | 50 +++ templates/editorconfig/c/.gitkeep | 0 templates/editorconfig/c_cxx/.editorconfig | 55 +++ templates/editorconfig/c_cxx/.gitkeep | 0 templates/editorconfig/cxx/.editorconfig | 50 +++ templates/editorconfig/cxx/.gitkeep | 0 templates/editorconfig/generic/.editorconfig | 99 +++++ templates/editorconfig/generic/.gitkeep | 0 templates/editorconfig/go/.editorconfig | 39 ++ templates/editorconfig/go/.gitkeep | 0 .../editorconfig/javascript/.editorconfig | 39 ++ templates/editorconfig/javascript/.gitkeep | 0 templates/editorconfig/python/.editorconfig | 44 +++ templates/editorconfig/python/.gitkeep | 0 templates/editorconfig/ruby/.editorconfig | 64 +++ templates/editorconfig/ruby/.gitkeep | 0 templates/editorconfig/rust/.editorconfig | 44 +++ templates/editorconfig/rust/.gitkeep | 0 templates/editorconfig/zig/.editorconfig | 39 ++ templates/editorconfig/zig/.gitkeep | 0 templates/gitattributes/README.md | 158 +++++++- templates/gitattributes/c#/.gitattributes | 77 ++++ templates/gitattributes/c#/.gitkeep | 0 templates/gitattributes/c/.gitattributes | 85 ++++ templates/gitattributes/c/.gitkeep | 0 templates/gitattributes/c_cxx/.gitattributes | 99 +++++ templates/gitattributes/c_cxx/.gitkeep | 0 templates/gitattributes/cxx/.gitattributes | 99 +++++ templates/gitattributes/cxx/.gitkeep | 0 .../gitattributes/generic/.gitattributes | 217 +++++++++++ templates/gitattributes/generic/.gitkeep | 0 templates/gitattributes/go/.gitattributes | 67 ++++ templates/gitattributes/go/.gitkeep | 0 .../gitattributes/javascript/.gitattributes | 89 +++++ templates/gitattributes/javascript/.gitkeep | 0 templates/gitattributes/python/.gitattributes | 90 +++++ templates/gitattributes/python/.gitkeep | 0 templates/gitattributes/ruby/.gitattributes | 75 ++++ templates/gitattributes/ruby/.gitkeep | 0 templates/gitattributes/rust/.gitattributes | 68 ++++ templates/gitattributes/rust/.gitkeep | 0 templates/gitattributes/zig/.gitattributes | 68 ++++ templates/gitattributes/zig/.gitkeep | 0 templates/gitignore/README.md | 8 +- templates/gitignore/c#/.gitignore | 40 ++ templates/gitignore/c#/.gitkeep | 0 templates/gitignore/c/.gitignore | 46 +++ templates/gitignore/c/.gitkeep | 0 templates/gitignore/c_cxx/.gitignore | 46 +++ templates/gitignore/c_cxx/.gitkeep | 0 templates/gitignore/cxx/.gitignore | 46 +++ templates/gitignore/cxx/.gitkeep | 0 templates/gitignore/generic/.gitignore | 38 ++ templates/gitignore/generic/.gitkeep | 0 templates/gitignore/go/.gitignore | 33 ++ templates/gitignore/go/.gitkeep | 0 templates/gitignore/javascript/.gitignore | 28 ++ templates/gitignore/javascript/.gitkeep | 0 templates/gitignore/python/.gitignore | 33 ++ templates/gitignore/python/.gitkeep | 0 templates/gitignore/ruby/.gitignore | 35 ++ templates/gitignore/ruby/.gitkeep | 0 templates/gitignore/rust/.gitignore | 27 ++ templates/gitignore/rust/.gitkeep | 0 templates/gitignore/zig/.gitignore | 24 ++ templates/gitignore/zig/.gitkeep | 0 templates/vimrc/README.md | 10 +- templates/vimrc/c#/.gitkeep | 0 templates/vimrc/c#/.vimrc | 66 ++++ templates/vimrc/c/.gitkeep | 0 templates/vimrc/c/.vimrc | 70 ++++ templates/vimrc/c_cxx/.vimrc | 14 +- templates/vimrc/cxx/.gitkeep | 0 templates/vimrc/cxx/.vimrc | 70 ++++ templates/vimrc/generic/.gitkeep | 0 templates/vimrc/generic/.vimrc | 82 ++++ templates/vimrc/go/.gitkeep | 0 templates/vimrc/go/.vimrc | 54 +++ templates/vimrc/javascript/.gitkeep | 0 templates/vimrc/javascript/.vimrc | 54 +++ templates/vimrc/python/.gitkeep | 0 templates/vimrc/python/.vimrc | 57 +++ templates/vimrc/ruby/.gitkeep | 0 templates/vimrc/ruby/.vimrc | 70 ++++ templates/vimrc/rust/.gitkeep | 0 templates/vimrc/rust/.vimrc | 70 ++++ templates/vimrc/zig/.gitkeep | 0 templates/vimrc/zig/.vimrc | 64 +++ templates/vscode/README.md | 165 +++++++- templates/vscode/c#/.gitkeep | 0 templates/vscode/c#/settings.json | 44 +++ templates/vscode/c/.gitkeep | 0 templates/vscode/c/settings.json | 197 ++++++++++ templates/vscode/c_cxx/.gitkeep | 0 templates/vscode/c_cxx/settings.json | 197 ++++++++++ templates/vscode/cxx/.gitkeep | 0 templates/vscode/cxx/settings.json | 197 ++++++++++ templates/vscode/generic/.gitkeep | 0 templates/vscode/generic/settings.json | 363 ++++++++++++++++++ templates/vscode/go/.gitkeep | 0 templates/vscode/go/settings.json | 70 ++++ templates/vscode/javascript/.gitkeep | 0 templates/vscode/javascript/settings.json | 80 ++++ templates/vscode/python/.gitkeep | 0 templates/vscode/python/settings.json | 60 +++ templates/vscode/ruby/.gitkeep | 0 templates/vscode/ruby/settings.json | 43 +++ templates/vscode/rust/.gitkeep | 0 templates/vscode/rust/settings.json | 57 +++ templates/vscode/zig/.gitkeep | 0 templates/vscode/zig/settings.json | 36 ++ 120 files changed, 4338 insertions(+), 70 deletions(-) create mode 100644 templates/editorconfig/c#/.editorconfig delete mode 100644 templates/editorconfig/c#/.gitkeep create mode 100644 templates/editorconfig/c/.editorconfig delete mode 100644 templates/editorconfig/c/.gitkeep create mode 100644 templates/editorconfig/c_cxx/.editorconfig delete mode 100644 templates/editorconfig/c_cxx/.gitkeep create mode 100644 templates/editorconfig/cxx/.editorconfig delete mode 100644 templates/editorconfig/cxx/.gitkeep create mode 100644 templates/editorconfig/generic/.editorconfig delete mode 100644 templates/editorconfig/generic/.gitkeep create mode 100644 templates/editorconfig/go/.editorconfig delete mode 100644 templates/editorconfig/go/.gitkeep create mode 100644 templates/editorconfig/javascript/.editorconfig delete mode 100644 templates/editorconfig/javascript/.gitkeep create mode 100644 templates/editorconfig/python/.editorconfig delete mode 100644 templates/editorconfig/python/.gitkeep create mode 100644 templates/editorconfig/ruby/.editorconfig delete mode 100644 templates/editorconfig/ruby/.gitkeep create mode 100644 templates/editorconfig/rust/.editorconfig delete mode 100644 templates/editorconfig/rust/.gitkeep create mode 100644 templates/editorconfig/zig/.editorconfig delete mode 100644 templates/editorconfig/zig/.gitkeep create mode 100644 templates/gitattributes/c#/.gitattributes delete mode 100644 templates/gitattributes/c#/.gitkeep create mode 100644 templates/gitattributes/c/.gitattributes delete mode 100644 templates/gitattributes/c/.gitkeep create mode 100644 templates/gitattributes/c_cxx/.gitattributes delete mode 100644 templates/gitattributes/c_cxx/.gitkeep create mode 100644 templates/gitattributes/cxx/.gitattributes delete mode 100644 templates/gitattributes/cxx/.gitkeep create mode 100644 templates/gitattributes/generic/.gitattributes delete mode 100644 templates/gitattributes/generic/.gitkeep create mode 100644 templates/gitattributes/go/.gitattributes delete mode 100644 templates/gitattributes/go/.gitkeep create mode 100644 templates/gitattributes/javascript/.gitattributes delete mode 100644 templates/gitattributes/javascript/.gitkeep create mode 100644 templates/gitattributes/python/.gitattributes delete mode 100644 templates/gitattributes/python/.gitkeep create mode 100644 templates/gitattributes/ruby/.gitattributes delete mode 100644 templates/gitattributes/ruby/.gitkeep create mode 100644 templates/gitattributes/rust/.gitattributes delete mode 100644 templates/gitattributes/rust/.gitkeep create mode 100644 templates/gitattributes/zig/.gitattributes delete mode 100644 templates/gitattributes/zig/.gitkeep create mode 100644 templates/gitignore/c#/.gitignore delete mode 100644 templates/gitignore/c#/.gitkeep create mode 100644 templates/gitignore/c/.gitignore delete mode 100644 templates/gitignore/c/.gitkeep create mode 100644 templates/gitignore/c_cxx/.gitignore delete mode 100644 templates/gitignore/c_cxx/.gitkeep create mode 100644 templates/gitignore/cxx/.gitignore delete mode 100644 templates/gitignore/cxx/.gitkeep create mode 100644 templates/gitignore/generic/.gitignore delete mode 100644 templates/gitignore/generic/.gitkeep create mode 100644 templates/gitignore/go/.gitignore delete mode 100644 templates/gitignore/go/.gitkeep create mode 100644 templates/gitignore/javascript/.gitignore delete mode 100644 templates/gitignore/javascript/.gitkeep create mode 100644 templates/gitignore/python/.gitignore delete mode 100644 templates/gitignore/python/.gitkeep create mode 100644 templates/gitignore/ruby/.gitignore delete mode 100644 templates/gitignore/ruby/.gitkeep create mode 100644 templates/gitignore/rust/.gitignore delete mode 100644 templates/gitignore/rust/.gitkeep create mode 100644 templates/gitignore/zig/.gitignore delete mode 100644 templates/gitignore/zig/.gitkeep delete mode 100644 templates/vimrc/c#/.gitkeep create mode 100644 templates/vimrc/c#/.vimrc delete mode 100644 templates/vimrc/c/.gitkeep create mode 100644 templates/vimrc/c/.vimrc delete mode 100644 templates/vimrc/cxx/.gitkeep create mode 100644 templates/vimrc/cxx/.vimrc delete mode 100644 templates/vimrc/generic/.gitkeep create mode 100644 templates/vimrc/generic/.vimrc delete mode 100644 templates/vimrc/go/.gitkeep create mode 100644 templates/vimrc/go/.vimrc delete mode 100644 templates/vimrc/javascript/.gitkeep create mode 100644 templates/vimrc/javascript/.vimrc delete mode 100644 templates/vimrc/python/.gitkeep create mode 100644 templates/vimrc/python/.vimrc delete mode 100644 templates/vimrc/ruby/.gitkeep create mode 100644 templates/vimrc/ruby/.vimrc delete mode 100644 templates/vimrc/rust/.gitkeep create mode 100644 templates/vimrc/rust/.vimrc delete mode 100644 templates/vimrc/zig/.gitkeep create mode 100644 templates/vimrc/zig/.vimrc delete mode 100644 templates/vscode/c#/.gitkeep create mode 100644 templates/vscode/c#/settings.json delete mode 100644 templates/vscode/c/.gitkeep create mode 100644 templates/vscode/c/settings.json delete mode 100644 templates/vscode/c_cxx/.gitkeep create mode 100644 templates/vscode/c_cxx/settings.json delete mode 100644 templates/vscode/cxx/.gitkeep create mode 100644 templates/vscode/cxx/settings.json delete mode 100644 templates/vscode/generic/.gitkeep create mode 100644 templates/vscode/generic/settings.json delete mode 100644 templates/vscode/go/.gitkeep create mode 100644 templates/vscode/go/settings.json delete mode 100644 templates/vscode/javascript/.gitkeep create mode 100644 templates/vscode/javascript/settings.json delete mode 100644 templates/vscode/python/.gitkeep create mode 100644 templates/vscode/python/settings.json delete mode 100644 templates/vscode/ruby/.gitkeep create mode 100644 templates/vscode/ruby/settings.json delete mode 100644 templates/vscode/rust/.gitkeep create mode 100644 templates/vscode/rust/settings.json delete mode 100644 templates/vscode/zig/.gitkeep create mode 100644 templates/vscode/zig/settings.json diff --git a/CHANGES.md b/CHANGES.md index f5d7002..36fe598 100644 --- a/CHANGES.md +++ b/CHANGES.md @@ -3,6 +3,7 @@ ## Table of Contents +- [0.6.0 - 15th September 2026](#060---15th-september-2026) - [0.5.3 - 15th September 2026](#053---15th-september-2026) - [0.5.2 - 15th September 2026](#052---15th-september-2026) - [0.5.1 - 14th September 2026](#051---14th-september-2026) @@ -15,6 +16,19 @@ - [0.1.1 - 11th August 2026](#011---11th-august-2026) +## 0.6.0 - 15th September 2026 + +* Phase 2: populate **templates/** as the canonical project drop-in catalogue: + * **templates/vscode/** — migrated from **misc-config-scripts** `settings.json/` (plus **c_cxx** alias of **cxx**); + * **templates/gitattributes/** — migrated from **misc-config-scripts** `gitattributes/`; + * **templates/vimrc/** — freelibs language gold plus synthesized **javascript** / **generic**; + * **templates/editorconfig/** — freelibs **python** / **ruby** plus synthesized house rules for other languages; + * **templates/gitignore/** — lean Synesis-header consensus per language; +* **templates/vimrc/**: lexicographically ordered language sections and combined `[label]` / `FileType` lists (revisibility); +* Updated **templates/** READMEs (status, copy commands, layout); +* Updated **README.md** (Phase 2 canonical; prefer **templates/** over legacy m-c-s catalogs); + + ## 0.5.3 - 15th September 2026 * Phase 1 self boilerplate: diff --git a/NEWS.md b/NEWS.md index 0704024..47ff0c3 100644 --- a/NEWS.md +++ b/NEWS.md @@ -3,6 +3,7 @@ | Date | News Item | Details | | -------------------- | --------- | ------- | +| 15th September 2026 | [**misc-dev-scripts** 0.6.0](https://github.com/synesissoftware/misc-dev-scripts/releases/tag/0.6.0) released | Phase 2: populate `templates/` catalogue | | 15th September 2026 | [**misc-dev-scripts** 0.5.3](https://github.com/synesissoftware/misc-dev-scripts/releases/tag/0.5.3) released | Phase 1 self boilerplate; c_cxx vimrc seed | | 15th September 2026 | [**misc-dev-scripts** 0.5.2](https://github.com/synesissoftware/misc-dev-scripts/releases/tag/0.5.2) released | Phase 0 ownership; `templates/` scaffold | | 14th September 2026 | [**misc-dev-scripts** 0.5.1](https://github.com/synesissoftware/misc-dev-scripts/releases/tag/0.5.1) released | Python `.sis` help + prefer project `.venv` | diff --git a/README.md b/README.md index abc1749..8d47a90 100644 --- a/README.md +++ b/README.md @@ -5,7 +5,7 @@ Miscellaneous Development Scripts ![Language](https://img.shields.io/badge/language-Bash-blue.svg) [![License](https://img.shields.io/badge/License-BSD_3--Clause-blue.svg)](https://opensource.org/licenses/BSD-3-Clause) -[![Version](https://img.shields.io/badge/version-0.5.3-blue.svg)](https://github.com/synesissoftware/misc-dev-scripts/blob/master/CHANGES.md) +[![Version](https://img.shields.io/badge/version-0.6.0-blue.svg)](https://github.com/synesissoftware/misc-dev-scripts/blob/master/CHANGES.md) [![Last Commit](https://img.shields.io/github/last-commit/synesissoftware/misc-dev-scripts)](https://github.com/synesissoftware/misc-dev-scripts/commits/master) [![CI](https://github.com/synesissoftware/misc-dev-scripts/actions/workflows/ci.yml/badge.svg)](https://github.com/synesissoftware/misc-dev-scripts/actions/workflows/ci.yml) @@ -33,7 +33,7 @@ Sibling project: [**misc-config-scripts**](https://github.com/synesissoftware/mi ## Ownership and migration (Phase 0) -**Status: Phase 0–1 done for self boilerplate — template content cutover not complete.** +**Status: Phase 2 complete — `templates/` is populated and is the canonical home for project drop-ins.** Legacy copies may still exist in **misc-config-scripts** until that repo’s Phase 3. Distinguish **self** boilerplate (this repository’s own root editor/Git files) from **templates** (copied into other projects). @@ -43,7 +43,7 @@ Distinguish **self** boilerplate (this repository’s own root editor/Git files) | **Templates:** **`.gitconfig`**, **`.commonrc`** | ✅ only | ❌ | | **Templates:** language-specific **`run_all_unit_tests.sh`**, **`.editorconfig`**, **`.gitattributes`**, **`.gitignore`**, **`.vimrc`**, **`.vscode/settings.json`** | ❌ (legacy frozen) | ✅ only | -Until later phases populate **`templates/`**, continue copying VS Code settings and **`.gitattributes`** from **misc-config-scripts** (legacy catalogs). Do **not** add new language templates there. +Until **misc-config-scripts** Phase 3 removes its legacy trees, prefer **this** repository’s **`templates/`** for new copies of VS Code settings and **`.gitattributes`**. Do **not** add new language templates under **misc-config-scripts**. ## Catalogue layout @@ -93,7 +93,7 @@ See [**templates/README.md**](./templates/README.md). Families: * [**vimrc**](./templates/vimrc/README.md); * [**vscode**](./templates/vscode/README.md); -**Phase 0–1:** directories reserved; **`templates/vimrc/c_cxx/.vimrc`** seeded. Other families not ready to copy. +**Phase 2:** all families populated for every language key — ready to copy. ## Related projects diff --git a/TODO.md b/TODO.md index 7e10780..26c0909 100644 --- a/TODO.md +++ b/TODO.md @@ -90,7 +90,7 @@ * [x] Add nested **shell-scripts/run_all_unit_tests/README.md** (copy command, per-lang paths, layout contracts, flag table); * [x] ~~~Phase 0: declare ownership; scaffold **templates/** catalogue layout + READMEs~~~ - ✅; * [x] ~~~Phase 1: complete **self** boilerplate (**`.editorconfig`**; retarget root **`.vimrc`** as self for this Bash catalog, not C/C++ consumer gold; seed **templates/vimrc/c_cxx/.vimrc**)~~~ - ✅; -* [ ] Phase 2: populate **templates/** from freelibs exemplars and migrate **misc-config-scripts** `settings.json/` + `gitattributes/` content; +* [x] ~~~Phase 2: populate **templates/** from freelibs exemplars and migrate **misc-config-scripts** `settings.json/` + `gitattributes/` content~~~ - ✅; * [ ] Phase 4: refresh this repo’s self **`.vscode/settings.json`** (and related self files) from **templates/vscode/generic/** (or shell-appropriate) once populated; * [ ] Later: hoist **build_dist.sh** / **build_dist_uv.sh** (Python), **build_gem.sh** (Ruby), **rustfmt.toml** / **scripts/fmt** (Rust), Go **build.sh** / runners, and further common helpers under **shell-scripts/** or **templates/** as appropriate; * [ ] Optional: sample bootstrap notes for copy-vs-sync adoption; diff --git a/VERSION b/VERSION index be14282..a918a2a 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -0.5.3 +0.6.0 diff --git a/templates/README.md b/templates/README.md index 822d03e..9170bde 100644 --- a/templates/README.md +++ b/templates/README.md @@ -3,7 +3,7 @@ Language-specific **project** drop-in templates for Synesis (and related) libraries. -This tree is the **canonical catalogue layout** for project-local config files that consumers copy into a repository root (or **`.vscode/`**). Content is staged here in phases; until a language directory holds a real template file, a **`.gitkeep`** marks the reserved path. +This tree is the **canonical catalogue** for project-local config files that consumers copy into a repository root (or **`.vscode/`**). ## Table of Contents @@ -13,20 +13,20 @@ This tree is the **canonical catalogue layout** for project-local config files t - [Ownership](#ownership) - [Layout](#layout) - [Language keys](#language-keys) -- [How to use (once populated)](#how-to-use-once-populated) +- [How to use](#how-to-use) - [Related](#related) ## Status -**Phase 0–1:** directory tree and documentation declared; **`templates/vimrc/c_cxx/.vimrc`** seeded (C/C++ gold preserved from former root self files). Other language folders remain empty (**`.gitkeep`**) until Phase 2. Do **not** treat unseeded folders as ready to copy. Cutover from **misc-config-scripts** remains a later phase. +**Phase 2 (populated):** all five families × eleven language keys hold copyable templates. Prefer these paths over the legacy catalogs still present (frozen) in **misc-config-scripts** `settings.json/` and `gitattributes/` until that repo’s Phase 3 removal. ## Self boilerplate vs templates | Kind | Where | Purpose | | --- | --- | --- | -| **Self** | Repository root (e.g. this project's own **`.vimrc`**, **`.gitignore`**) | Configures *this* repository | +| **Self** | Repository root (e.g. this project’s own **`.vimrc`**, **`.gitignore`**) | Configures *this* repository | | **Template** | Under **`templates///`** | Copied into *other* projects | Do not confuse root self files with the catalogue under **`templates/`**. @@ -36,11 +36,11 @@ Do not confuse root self files with the catalogue under **`templates/`**. | Template family | Canonical home | Notes | | --- | --- | --- | -| **.editorconfig** | **misc-dev-scripts** `templates/editorconfig/` | Intent; content TBD | -| **.gitattributes** | **misc-dev-scripts** `templates/gitattributes/` | Today still shipped from **misc-config-scripts** `gitattributes/` (deprecated for new work) | -| **.gitignore** | **misc-dev-scripts** `templates/gitignore/` | Intent; content TBD | -| **.vimrc** | **misc-dev-scripts** `templates/vimrc/` | Intent; content TBD | -| **.vscode** (`settings.json`) | **misc-dev-scripts** `templates/vscode/` | Today still shipped from **misc-config-scripts** `settings.json/` (deprecated for new work) | +| **editorconfig** | **misc-dev-scripts** `templates/editorconfig/` | Seeded from freelibs exemplars + house indent rules | +| **gitattributes** | **misc-dev-scripts** `templates/gitattributes/` | Migrated from **misc-config-scripts** `gitattributes/` | +| **gitignore** | **misc-dev-scripts** `templates/gitignore/` | Lean Synesis-header consensus per language | +| **vimrc** | **misc-dev-scripts** `templates/vimrc/` | Freelibs language gold (+ synthesized JS / generic) | +| **vscode** (`settings.json`) | **misc-dev-scripts** `templates/vscode/` | Migrated from **misc-config-scripts** `settings.json/` | | **run_all_unit_tests.sh** | **misc-dev-scripts** `shell-scripts/run_all_unit_tests/` | Already canonical | | **.gitconfig** / **.commonrc** | **misc-config-scripts** only | Machine / shell environment — not project drop-ins | @@ -75,7 +75,7 @@ Lexicographic language directory names (same set for every family): * **zig**. -## How to use (once populated) +## How to use ```sh cp templates/vscode/python/settings.json /path/to/repo/.vscode/settings.json @@ -91,7 +91,7 @@ When updating a consumer, cite this repository’s **VERSION** in that project ## Related * [**shell-scripts/run_all_unit_tests/README.md**](../shell-scripts/run_all_unit_tests/README.md) — test-runner helpers; -* Sibling [**misc-config-scripts**](https://github.com/synesissoftware/misc-config-scripts) — **`.gitconfig`** and **`.commonrc`** only (after cutover); project dotfile catalogs there are frozen pending migration. +* Sibling [**misc-config-scripts**](https://github.com/synesissoftware/misc-config-scripts) — **`.gitconfig`** and **`.commonrc`**; legacy project catalogs frozen until Phase 3. diff --git a/templates/editorconfig/README.md b/templates/editorconfig/README.md index cf88c04..e1f3ee1 100644 --- a/templates/editorconfig/README.md +++ b/templates/editorconfig/README.md @@ -3,16 +3,16 @@ Drop-in root **`.editorconfig`** files, organised by primary language. -**Status:** Phase 0 — layout only (**`.gitkeep`** placeholders). Content lands in a later phase. +**Status:** Phase 2 — populated (freelibs exemplars for **python** / **ruby**; synthesized house indent rules for other languages). ## Table of Contents -- [How to use (once populated)](#how-to-use-once-populated) +- [How to use](#how-to-use) - [Layout](#layout) -## How to use (once populated) +## How to use ```sh cp templates/editorconfig//.editorconfig /path/to/repo/.editorconfig diff --git a/templates/editorconfig/c#/.editorconfig b/templates/editorconfig/c#/.editorconfig new file mode 100644 index 0000000..6a17d8f --- /dev/null +++ b/templates/editorconfig/c#/.editorconfig @@ -0,0 +1,44 @@ +root = true + +# Language indent/EOL/charset overlap with .vscode/settings.json. +# Rulers, renderWhitespace, detectIndentation, mergeEditor, and +# language-server settings cannot be expressed here — they stay in +# settings.json. + +[*] +charset = utf-8 +end_of_line = lf +indent_size = 2 +indent_style = tab +insert_final_newline = true +trim_trailing_whitespace = true + +# [csharp] +[*.{cs,csx}] +indent_size = 4 +indent_style = space + +# [json] +[*.json] +indent_size = 2 +indent_style = space + +# [markdown] +[*.md] +indent_size = 2 +indent_style = space + +# [shellscript] +[*.{bash,sh,zsh}] +indent_size = 2 +indent_style = space + +# [xml] — SDK-style .csproj / .props / .targets +[*.{csproj,props,targets,xml}] +indent_size = 2 +indent_style = space + +# [yaml] +[*.{yaml,yml}] +indent_size = 2 +indent_style = space diff --git a/templates/editorconfig/c#/.gitkeep b/templates/editorconfig/c#/.gitkeep deleted file mode 100644 index e69de29..0000000 diff --git a/templates/editorconfig/c/.editorconfig b/templates/editorconfig/c/.editorconfig new file mode 100644 index 0000000..b409470 --- /dev/null +++ b/templates/editorconfig/c/.editorconfig @@ -0,0 +1,50 @@ +root = true + +# Language indent/EOL/charset overlap with .vscode/settings.json. +# Rulers, renderWhitespace, detectIndentation, mergeEditor, and +# language-server settings cannot be expressed here — they stay in +# settings.json. + +[*] +charset = utf-8 +end_of_line = lf +indent_size = 2 +indent_style = tab +insert_final_newline = true +trim_trailing_whitespace = true + +# [bat] +[*.{bat,cmd}] +end_of_line = crlf +indent_size = 4 +indent_style = space + +# [c] +[*.{c,h}] +indent_size = 4 +indent_style = space + +# [cmake] +[{CMakeLists.txt,*.cmake}] +indent_size = 4 +indent_style = tab + +# [json] +[*.json] +indent_size = 2 +indent_style = space + +# [markdown] +[*.md] +indent_size = 2 +indent_style = space + +# [shellscript] +[*.{bash,sh,zsh}] +indent_size = 2 +indent_style = space + +# [yaml] +[*.{yaml,yml}] +indent_size = 2 +indent_style = space diff --git a/templates/editorconfig/c/.gitkeep b/templates/editorconfig/c/.gitkeep deleted file mode 100644 index e69de29..0000000 diff --git a/templates/editorconfig/c_cxx/.editorconfig b/templates/editorconfig/c_cxx/.editorconfig new file mode 100644 index 0000000..47f1966 --- /dev/null +++ b/templates/editorconfig/c_cxx/.editorconfig @@ -0,0 +1,55 @@ +root = true + +# Language indent/EOL/charset overlap with .vscode/settings.json. +# Rulers, renderWhitespace, detectIndentation, mergeEditor, and +# language-server settings cannot be expressed here — they stay in +# settings.json. + +[*] +charset = utf-8 +end_of_line = lf +indent_size = 2 +indent_style = tab +insert_final_newline = true +trim_trailing_whitespace = true + +# [bat] +[*.{bat,cmd}] +end_of_line = crlf +indent_size = 4 +indent_style = space + +# [c] +[*.{c,h}] +indent_size = 4 +indent_style = space + +# [cmake] +[{CMakeLists.txt,*.cmake}] +indent_size = 4 +indent_style = tab + +# [cpp] +[*.{cpp,cxx,hpp,hxx}] +indent_size = 4 +indent_style = space + +# [json] +[*.json] +indent_size = 2 +indent_style = space + +# [markdown] +[*.md] +indent_size = 2 +indent_style = space + +# [shellscript] +[*.{bash,sh,zsh}] +indent_size = 2 +indent_style = space + +# [yaml] +[*.{yaml,yml}] +indent_size = 2 +indent_style = space diff --git a/templates/editorconfig/c_cxx/.gitkeep b/templates/editorconfig/c_cxx/.gitkeep deleted file mode 100644 index e69de29..0000000 diff --git a/templates/editorconfig/cxx/.editorconfig b/templates/editorconfig/cxx/.editorconfig new file mode 100644 index 0000000..6653127 --- /dev/null +++ b/templates/editorconfig/cxx/.editorconfig @@ -0,0 +1,50 @@ +root = true + +# Language indent/EOL/charset overlap with .vscode/settings.json. +# Rulers, renderWhitespace, detectIndentation, mergeEditor, and +# language-server settings cannot be expressed here — they stay in +# settings.json. + +[*] +charset = utf-8 +end_of_line = lf +indent_size = 2 +indent_style = tab +insert_final_newline = true +trim_trailing_whitespace = true + +# [bat] +[*.{bat,cmd}] +end_of_line = crlf +indent_size = 4 +indent_style = space + +# [cmake] +[{CMakeLists.txt,*.cmake}] +indent_size = 4 +indent_style = tab + +# [cpp] +[*.{cpp,cxx,hpp,hxx}] +indent_size = 4 +indent_style = space + +# [json] +[*.json] +indent_size = 2 +indent_style = space + +# [markdown] +[*.md] +indent_size = 2 +indent_style = space + +# [shellscript] +[*.{bash,sh,zsh}] +indent_size = 2 +indent_style = space + +# [yaml] +[*.{yaml,yml}] +indent_size = 2 +indent_style = space diff --git a/templates/editorconfig/cxx/.gitkeep b/templates/editorconfig/cxx/.gitkeep deleted file mode 100644 index e69de29..0000000 diff --git a/templates/editorconfig/generic/.editorconfig b/templates/editorconfig/generic/.editorconfig new file mode 100644 index 0000000..6c8ff94 --- /dev/null +++ b/templates/editorconfig/generic/.editorconfig @@ -0,0 +1,99 @@ +root = true + +# Language indent/EOL/charset overlap with .vscode/settings.json (generic). +# Rulers, renderWhitespace, detectIndentation, mergeEditor, and +# language-server settings cannot be expressed here — they stay in +# settings.json. + +[*] +charset = utf-8 +end_of_line = lf +indent_size = 2 +indent_style = tab +insert_final_newline = true +trim_trailing_whitespace = true + +# [bat] +[*.{bat,cmd}] +end_of_line = crlf +indent_size = 4 +indent_style = space + +# [c] +[*.{c,h}] +indent_size = 4 +indent_style = space + +# [cmake] +[{CMakeLists.txt,*.cmake}] +indent_size = 4 +indent_style = tab + +# [cpp] +[*.{cpp,cxx,hpp,hxx}] +indent_size = 4 +indent_style = space + +# [csharp] +[*.{cs,csx}] +indent_size = 4 +indent_style = space + +# [go] +[*.go] +indent_size = 2 +indent_style = tab + +# [javascript] / [typescript] +[*.{cjs,js,jsx,mjs,ts,tsx}] +indent_size = 2 +indent_style = space + +# [json] +[*.json] +indent_size = 2 +indent_style = space + +# [markdown] +[*.md] +indent_size = 2 +indent_style = space + +# [python] +[*.py] +indent_size = 4 +indent_style = space + +# [ruby] +[*.{gemspec,rb}] +indent_size = 2 +indent_style = space + +[{Gemfile,Rakefile}] +indent_size = 2 +indent_style = space + +# [rust] +[*.rs] +indent_size = 4 +indent_style = space + +# [shellscript] +[*.{bash,sh,zsh}] +indent_size = 2 +indent_style = space + +# [toml] +[*.toml] +indent_size = 2 +indent_style = tab + +# [yaml] +[*.{yaml,yml}] +indent_size = 2 +indent_style = space + +# [zig] +[*.zig] +indent_size = 4 +indent_style = space diff --git a/templates/editorconfig/generic/.gitkeep b/templates/editorconfig/generic/.gitkeep deleted file mode 100644 index e69de29..0000000 diff --git a/templates/editorconfig/go/.editorconfig b/templates/editorconfig/go/.editorconfig new file mode 100644 index 0000000..8222f80 --- /dev/null +++ b/templates/editorconfig/go/.editorconfig @@ -0,0 +1,39 @@ +root = true + +# Language indent/EOL/charset overlap with .vscode/settings.json. +# Rulers, renderWhitespace, detectIndentation, mergeEditor, and +# language-server settings cannot be expressed here — they stay in +# settings.json. + +[*] +charset = utf-8 +end_of_line = lf +indent_size = 2 +indent_style = tab +insert_final_newline = true +trim_trailing_whitespace = true + +# [go] — gofmt uses tabs +[*.go] +indent_size = 2 +indent_style = tab + +# [json] +[*.json] +indent_size = 2 +indent_style = space + +# [markdown] +[*.md] +indent_size = 2 +indent_style = space + +# [shellscript] +[*.{bash,sh,zsh}] +indent_size = 2 +indent_style = space + +# [yaml] +[*.{yaml,yml}] +indent_size = 2 +indent_style = space diff --git a/templates/editorconfig/go/.gitkeep b/templates/editorconfig/go/.gitkeep deleted file mode 100644 index e69de29..0000000 diff --git a/templates/editorconfig/javascript/.editorconfig b/templates/editorconfig/javascript/.editorconfig new file mode 100644 index 0000000..7b9b59c --- /dev/null +++ b/templates/editorconfig/javascript/.editorconfig @@ -0,0 +1,39 @@ +root = true + +# Language indent/EOL/charset overlap with .vscode/settings.json. +# Rulers, renderWhitespace, detectIndentation, mergeEditor, and +# language-server settings cannot be expressed here — they stay in +# settings.json. + +[*] +charset = utf-8 +end_of_line = lf +indent_size = 2 +indent_style = tab +insert_final_newline = true +trim_trailing_whitespace = true + +# [javascript] / [typescript] — Prettier / house 2-space +[*.{cjs,js,jsx,mjs,ts,tsx}] +indent_size = 2 +indent_style = space + +# [json] +[*.json] +indent_size = 2 +indent_style = space + +# [markdown] +[*.md] +indent_size = 2 +indent_style = space + +# [shellscript] +[*.{bash,sh,zsh}] +indent_size = 2 +indent_style = space + +# [yaml] +[*.{yaml,yml}] +indent_size = 2 +indent_style = space diff --git a/templates/editorconfig/javascript/.gitkeep b/templates/editorconfig/javascript/.gitkeep deleted file mode 100644 index e69de29..0000000 diff --git a/templates/editorconfig/python/.editorconfig b/templates/editorconfig/python/.editorconfig new file mode 100644 index 0000000..762ee86 --- /dev/null +++ b/templates/editorconfig/python/.editorconfig @@ -0,0 +1,44 @@ +root = true + +# Language indent/EOL/charset overlap with .vscode/settings.json. +# Rulers, renderWhitespace, detectIndentation, mergeEditor, and +# language-server settings cannot be expressed here — they stay in +# settings.json. + +[*] +charset = utf-8 +end_of_line = lf +indent_size = 2 +indent_style = tab +insert_final_newline = true +trim_trailing_whitespace = true + +# [json] +[*.json] +indent_size = 2 +indent_style = space + +# [markdown] +[*.md] +indent_size = 2 +indent_style = space + +# [python] +[*.py] +indent_size = 4 +indent_style = space + +# [shellscript] +[*.{bash,sh,zsh}] +indent_size = 2 +indent_style = space + +# [toml] +[*.toml] +indent_size = 2 +indent_style = tab + +# [yaml] +[*.{yaml,yml}] +indent_size = 2 +indent_style = space diff --git a/templates/editorconfig/python/.gitkeep b/templates/editorconfig/python/.gitkeep deleted file mode 100644 index e69de29..0000000 diff --git a/templates/editorconfig/ruby/.editorconfig b/templates/editorconfig/ruby/.editorconfig new file mode 100644 index 0000000..8d78c5d --- /dev/null +++ b/templates/editorconfig/ruby/.editorconfig @@ -0,0 +1,64 @@ +root = true + +# Language indent/EOL/charset overlap with .vscode/settings.json. +# Rulers, renderWhitespace, detectIndentation, mergeEditor, and +# cmake.configureOnOpen cannot be expressed here — they stay in settings.json. + +[*] +charset = utf-8 +end_of_line = lf +indent_size = 2 +indent_style = tab +insert_final_newline = true +trim_trailing_whitespace = true + +# [bat] +[*.{bat,cmd}] +end_of_line = crlf +indent_size = 4 +indent_style = space + +# [c] +[*.{c,h}] +indent_size = 4 +indent_style = space + +# [cmake] +[{CMakeLists.txt,*.cmake}] +indent_size = 4 +indent_style = tab + +# [cpp] +[*.{cpp,cxx,hpp,hxx}] +indent_size = 4 +indent_style = space + +# [json] +[*.json] +indent_size = 2 +indent_style = space + +# [markdown] +[*.md] +indent_size = 2 +indent_style = space +trim_trailing_whitespace = false + +# [ruby] +[*.{gemspec,rb}] +indent_size = 2 +indent_style = space + +[{Gemfile,Rakefile}] +indent_size = 2 +indent_style = space + +# [shellscript] +[*.{bash,sh,zsh}] +indent_size = 2 +indent_style = space + +# [yaml] +[*.{yaml,yml}] +indent_size = 2 +indent_style = space diff --git a/templates/editorconfig/ruby/.gitkeep b/templates/editorconfig/ruby/.gitkeep deleted file mode 100644 index e69de29..0000000 diff --git a/templates/editorconfig/rust/.editorconfig b/templates/editorconfig/rust/.editorconfig new file mode 100644 index 0000000..02228a4 --- /dev/null +++ b/templates/editorconfig/rust/.editorconfig @@ -0,0 +1,44 @@ +root = true + +# Language indent/EOL/charset overlap with .vscode/settings.json. +# Rulers, renderWhitespace, detectIndentation, mergeEditor, and +# language-server settings cannot be expressed here — they stay in +# settings.json. + +[*] +charset = utf-8 +end_of_line = lf +indent_size = 2 +indent_style = tab +insert_final_newline = true +trim_trailing_whitespace = true + +# [json] +[*.json] +indent_size = 2 +indent_style = space + +# [markdown] +[*.md] +indent_size = 2 +indent_style = space + +# [rust] +[*.rs] +indent_size = 4 +indent_style = space + +# [shellscript] +[*.{bash,sh,zsh}] +indent_size = 2 +indent_style = space + +# [toml] +[*.toml] +indent_size = 2 +indent_style = tab + +# [yaml] +[*.{yaml,yml}] +indent_size = 2 +indent_style = space diff --git a/templates/editorconfig/rust/.gitkeep b/templates/editorconfig/rust/.gitkeep deleted file mode 100644 index e69de29..0000000 diff --git a/templates/editorconfig/zig/.editorconfig b/templates/editorconfig/zig/.editorconfig new file mode 100644 index 0000000..06965af --- /dev/null +++ b/templates/editorconfig/zig/.editorconfig @@ -0,0 +1,39 @@ +root = true + +# Language indent/EOL/charset overlap with .vscode/settings.json. +# Rulers, renderWhitespace, detectIndentation, mergeEditor, and +# language-server settings cannot be expressed here — they stay in +# settings.json. + +[*] +charset = utf-8 +end_of_line = lf +indent_size = 2 +indent_style = tab +insert_final_newline = true +trim_trailing_whitespace = true + +# [json] +[*.json] +indent_size = 2 +indent_style = space + +# [markdown] +[*.md] +indent_size = 2 +indent_style = space + +# [shellscript] +[*.{bash,sh,zsh}] +indent_size = 2 +indent_style = space + +# [yaml] +[*.{yaml,yml}] +indent_size = 2 +indent_style = space + +# [zig] +[*.zig] +indent_size = 4 +indent_style = space diff --git a/templates/editorconfig/zig/.gitkeep b/templates/editorconfig/zig/.gitkeep deleted file mode 100644 index e69de29..0000000 diff --git a/templates/gitattributes/README.md b/templates/gitattributes/README.md index 0a0f324..8bfd9db 100644 --- a/templates/gitattributes/README.md +++ b/templates/gitattributes/README.md @@ -1,41 +1,165 @@ # `.gitattributes` templates -Drop-in root **`.gitattributes`** files, organised by primary language. +**Status:** Phase 2 — canonical copies live here (migrated from **misc-config-scripts** `gitattributes/`). -**Status:** Phase 0 — layout only (**`.gitkeep`** placeholders). Until cutover, copy from **misc-config-scripts** `gitattributes/` (frozen: no new language templates there). Content will be migrated here in a later phase. + +Drop-in root **`.gitattributes`** files for GitHub-hosted repositories, organised by primary language. + +These templates were written from first principles using public documentation and community templates — **not** from local Synesis / related repositories. ## Table of Contents -- [How to use (once populated)](#how-to-use-once-populated) +- [Formatting conventions in these files](#formatting-conventions-in-these-files) +- [How the contents were chosen](#how-the-contents-were-chosen) +- [How to use](#how-to-use) +- [Language templates](#language-templates) + - [c and cxx](#c-and-cxx) + - [csharp](#csharp) + - [generic](#generic) + - [go](#go) + - [javascript](#javascript) + - [python](#python) + - [ruby](#ruby) + - [rust](#rust) + - [zig](#zig) - [Layout](#layout) +- [Shared baseline](#shared-baseline) +- [What is intentionally omitted](#what-is-intentionally-omitted) + + +## Formatting conventions in these files + +* Comment header naming the language and citing primary sources; +* Section comments (`# --- … ---`) grouping related patterns; +* Within each section, patterns are listed in **lexicographic** order; +* One pattern per line; attributes space-separated after the pattern. + +## How the contents were chosen -## How to use (once populated) +1. **GitHub Docs — line endings** — Start every file with `* text=auto` so Git detects text vs binary and normalises text to LF in the repository ([Configuring Git to handle line endings](https://docs.github.com/en/get-started/getting-started-with-git/configuring-git-to-handle-line-endings)). +2. **git-scm — `gitattributes(5)`** — Attach built-in `diff=` drivers where Git provides them (`cpp`, `csharp`, `golang`, `python`, `ruby`, `rust`, `markdown`, `html`, `css`, …) for better hunk headers. +3. **Community templates** — Incorporate ecosystem patterns from [gitattributes/gitattributes](https://github.com/gitattributes/gitattributes) (`Common`, `C++`, `CSharp`, `Python`, `Rust`, `Go`, `Web`). +4. **GitHub Linguist** — Mark common generated / vendored / documentation paths with `linguist-generated`, `linguist-vendored`, `linguist-documentation`, and fix highlighting with `linguist-language` where needed ([Linguist overrides](https://github.com/github-linguist/linguist/blob/main/docs/overrides.md)). +5. **Modern GitHub practice over historical oddities** — e.g. Go uses `*.go text eol=lf` (gofmt-friendly on Windows), not the golang/go-repo `*.go -text` special case, unless you are contributing to that specific tree. + + +## How to use + +Copy the appropriate file to the target repository root as **`.gitattributes`**: ```sh cp templates/gitattributes//.gitattributes /path/to/repo/.gitattributes ``` -Prefer the language-specific template that matches the project’s primary language; use **generic** only for multi-language trees. Use **c_cxx** for mixed native C / C++ trees. +Prefer the language-specific template that matches the project’s primary language; use **generic** only for multi-language trees or when no single language dominates. + +After adding or changing `.gitattributes` in an existing repo, renormalise if needed: + +```sh +git add --renormalize . +``` + +Linguist overrides apply only after the `.gitattributes` file is **committed**. + + +## Language templates + +### c and cxx + +Folders: **`c/`**, **`cxx/`**. + +* **Source**: C/C++ extensions as `text diff=cpp` (Git’s `cpp` driver covers both languages). +* **Build**: Makefiles, Autotools, CMake as text; `configure` forced `eol=lf`. +* **Binary**: objects, static/shared libraries, executables, precompiled headers. +* **Linguist**: `build/` / `cmake-build-*/` as `linguist-generated` if ever committed (prefer `.gitignore`). + +### csharp + +Folder: **`c#/`**. + +* **Source**: `*.cs` / `*.csx` with `diff=csharp`; Razor/CSHTML with `diff=html`. +* **Solutions / projects**: `*.sln`, `*.csproj`, etc. use `eol=crlf` (Visual Studio expectation; matches gitattributes/CSharp template and GitHub Docs examples). +* **Linguist**: `bin/` / `obj/` generated; `packages/` vendored. + +### generic + +**Union** of every language-specific template (all source, config, script, binary, and Linguist rules). Prefer a single-language template when possible to avoid irrelevant patterns. + +### go + +* **Source**: `*.go text eol=lf diff=golang` plus `go.mod` / `go.sum` / `go.work*` with LF (avoids gofmt line-ending churn on Windows). +* **Note**: The [gitattributes Go template](https://github.com/gitattributes/gitattributes/blob/master/Go.gitattributes) uses `*.go -text` for the golang/go contribution style; this template follows common **GitHub-hosted** Go apps/libraries instead. +* **Linguist**: `vendor/` as `linguist-vendored`. + +### javascript + +* **Source**: JS/TS/JSX/TSX/Vue with LF; CSS/HTML with their diff drivers. +* **Lockfiles / maps**: kept as text but `-diff` to reduce noise (`package-lock.json`, `yarn.lock`, `pnpm-lock.yaml`, `*.map`). +* **Linguist**: minified assets and `dist/` / `build/` generated; `node_modules/` vendored; `tsconfig.json` / `jsconfig.json` as `JSON-with-Comments`. + +### python + +* **Source**: `*.py` / stubs / Cython with `diff=python`; notebooks LF. +* **Binary**: bytecode `*.pyc` / `*.pyo` as `binary export-ignore`; wheels, extensions, pickles as binary. +* **Linguist**: `__pycache__`, type/test/linter caches, `dist/`, `*.egg-info` generated. + +### ruby + +* **Source**: `*.rb`, gemspecs, Rakefile/Gemfile family with `diff=ruby` and LF. +* **Lock**: `Gemfile.lock` as text `-diff`. +* **Linguist**: Bundler vendor paths vendored; `coverage/` / `pkg/` generated; `doc/` documentation. + +### rust + +* **Source**: `*.rs text eol=lf diff=rust`; `Cargo.toml` / `Cargo.lock` / toolchain files as text. +* **Linguist**: `target/` as `linguist-generated` if committed (normally gitignored). + +### zig + +* **Source**: `*.zig` / `*.zon` / `build.zig*` as text LF (no built-in Git `diff=` driver for Zig). +* **Linguist**: `.zig-cache/`, `zig-cache/`, `zig-out/` generated if committed (normally gitignored per ziglang conventions). ## Layout | Path | Role | -| --- | --- | -| **c/** | C-primary | -| **c#/** | C# / .NET | -| **c_cxx/** | Mixed C / C++ | -| **cxx/** | C++-primary | -| **generic/** | Union / mixed | -| **go/** | Go | -| **javascript/** | JavaScript / TypeScript | -| **python/** | Python | -| **ruby/** | Ruby | -| **rust/** | Rust | -| **zig/** | Zig | +|---|---| +| **c#/.gitattributes** | C# / .NET projects | +| **c/.gitattributes** | C-primary projects | +| **c_cxx/.gitattributes** | Mixed C / C++ projects | +| **cxx/.gitattributes** | C++-primary projects | +| **generic/.gitattributes** | Union of all language templates | +| **go/.gitattributes** | Go projects | +| **javascript/.gitattributes** | JavaScript / TypeScript projects | +| **python/.gitattributes** | Python projects | +| **ruby/.gitattributes** | Ruby projects | +| **rust/.gitattributes** | Rust projects | +| **zig/.gitattributes** | Zig projects | + +Templates live under **`templates/gitattributes/`** (not `.gitattributes/`) so they do not collide with a repository’s own root `.gitattributes` file. + + +## Shared baseline + +Every template includes: + +* `* text=auto`; +* shell scripts with `eol=lf`, Windows scripts (`.bat` / `.cmd` / `.ps1`) with `eol=crlf`; +* common docs / licence / changelog names as text; +* common image and archive binaries; +* `.gitattributes` / `.gitignore` as text. + + +## What is intentionally omitted + +* Project-specific `linguist-language=` remaps (e.g. forcing headers to C vs C++); +* Absolute paths or machine-local patterns; +* Treating SVG as binary (left as text, matching Common/Web templates); +* Relying on Linguist alone for build dirs that should be **gitignored** instead; +* Custom `merge=` drivers (e.g. Rails `schema.rb merge=ours`) that need local git config. diff --git a/templates/gitattributes/c#/.gitattributes b/templates/gitattributes/c#/.gitattributes new file mode 100644 index 0000000..2f24346 --- /dev/null +++ b/templates/gitattributes/c#/.gitattributes @@ -0,0 +1,77 @@ +# .gitattributes — C# / .NET (GitHub-hosted) +# +# Sources: GitHub Docs (line endings), git-scm gitattributes (diff=csharp), +# gitattributes/gitattributes CSharp.gitattributes + Common.gitattributes, +# github-linguist overrides. + +# Default: detect text, normalize to LF in the repository +* text=auto + +# --- Source --- +*.cs text diff=csharp +*.csx text diff=csharp +*.cshtml text diff=html +*.razor text diff=html + +# --- Project / solution (Visual Studio expects CRLF) --- +*.csproj text eol=crlf +*.fsproj text eol=crlf +*.props text eol=crlf +*.sln text eol=crlf +*.slnx text eol=crlf +*.targets text eol=crlf +*.vbproj text eol=crlf + +# --- Scripts --- +*.bash text eol=lf +*.bat text eol=crlf +*.cmd text eol=crlf +*.ps1 text eol=crlf +*.sh text eol=lf +*.zsh text eol=lf + +# --- Docs / meta --- +*.adoc text +*.markdown text diff=markdown +*.md text diff=markdown +*.txt text +AUTHORS text +CHANGELOG text +CHANGES text +CONTRIBUTING text +COPYING text +LICENSE text +NEWS text +README text +TODO text +.gitattributes text +.gitignore text + +# --- Serialisation --- +*.json text +*.toml text +*.xml text +*.yaml text +*.yml text + +# --- Binary / NuGet --- +*.dll binary +*.exe binary +*.nupkg binary +*.pdb binary +*.snk binary + +# --- Archives / images (common) --- +*.gif binary +*.gz binary +*.ico binary +*.jpeg binary +*.jpg binary +*.png binary +*.tar binary +*.zip binary + +# --- GitHub Linguist --- +**/bin/** linguist-generated +**/obj/** linguist-generated +**/packages/** linguist-vendored diff --git a/templates/gitattributes/c#/.gitkeep b/templates/gitattributes/c#/.gitkeep deleted file mode 100644 index e69de29..0000000 diff --git a/templates/gitattributes/c/.gitattributes b/templates/gitattributes/c/.gitattributes new file mode 100644 index 0000000..d58dcc9 --- /dev/null +++ b/templates/gitattributes/c/.gitattributes @@ -0,0 +1,85 @@ +# .gitattributes — C (GitHub-hosted) +# +# Sources: GitHub Docs (line endings), git-scm gitattributes (diff=cpp), +# gitattributes/gitattributes C++.gitattributes + Common.gitattributes, +# github-linguist overrides. + +# Default: detect text, normalize to LF in the repository +* text=auto + +# --- Source --- +*.c text diff=cpp +*.h text diff=cpp +*.inc text +*.inl text + +# --- Build / config --- +*.am text +*.cmake text +*.m4 text +*.mak text +*.mk text +*akefile text +CMakeLists.txt text +configure text eol=lf +configure.ac text + +# --- Scripts --- +*.bash text eol=lf +*.bat text eol=crlf +*.cmd text eol=crlf +*.ps1 text eol=crlf +*.sh text eol=lf +*.zsh text eol=lf + +# --- Docs / meta --- +*.adoc text +*.markdown text diff=markdown +*.md text diff=markdown +*.txt text +AUTHORS text +CHANGELOG text +CHANGES text +CONTRIBUTING text +COPYING text +LICENSE text +NEWS text +README text +TODO text +.gitattributes text +.gitignore text + +# --- Serialisation --- +*.json text +*.toml text +*.xml text +*.yaml text +*.yml text + +# --- Compiled / binary artefacts --- +*.a binary +*.dll binary +*.dylib binary +*.exe binary +*.gch binary +*.lib binary +*.o binary +*.obj binary +*.out binary +*.pch binary +*.so binary + +# --- Archives / images (common) --- +*.gif binary +*.gz binary +*.ico binary +*.jpeg binary +*.jpg binary +*.png binary +*.tar binary +*.zip binary + +# --- GitHub Linguist --- +# Object / build trees if committed (prefer .gitignore; mark if present) +**/build/** linguist-generated +**/cmake-build-*/** linguist-generated diff --git a/templates/gitattributes/c/.gitkeep b/templates/gitattributes/c/.gitkeep deleted file mode 100644 index e69de29..0000000 diff --git a/templates/gitattributes/c_cxx/.gitattributes b/templates/gitattributes/c_cxx/.gitattributes new file mode 100644 index 0000000..76a2f86 --- /dev/null +++ b/templates/gitattributes/c_cxx/.gitattributes @@ -0,0 +1,99 @@ +# .gitattributes — C / C++ (GitHub-hosted) +# +# Sources: GitHub Docs (line endings), git-scm gitattributes (diff=cpp), +# gitattributes/gitattributes C++.gitattributes + Common.gitattributes, +# github-linguist overrides. + +# Default: detect text, normalize to LF in the repository +* text=auto + +# --- Source --- +*.c text diff=cpp +*.c++ text diff=cpp +*.cc text diff=cpp +*.cpp text diff=cpp +*.cxx text diff=cpp +*.h text diff=cpp +*.h++ text diff=cpp +*.hh text diff=cpp +*.hpp text diff=cpp +*.hxx text diff=cpp +*.inc text +*.inl text +*.ipp text +*.tcc text +*.tpp text + +# --- Build / config --- +*.am text +*.cmake text +*.m4 text +*.mak text +*.mk text +*akefile text +CMakeLists.txt text +configure text eol=lf +configure.ac text + +# --- Scripts --- +*.bash text eol=lf +*.bat text eol=crlf +*.cmd text eol=crlf +*.ps1 text eol=crlf +*.sh text eol=lf +*.zsh text eol=lf + +# --- Docs / meta --- +*.adoc text +*.markdown text diff=markdown +*.md text diff=markdown +*.txt text +AUTHORS text +CHANGELOG text +CHANGES text +CONTRIBUTING text +COPYING text +LICENSE text +NEWS text +README text +TODO text +.gitattributes text +.gitignore text + +# --- Serialisation --- +*.json text +*.toml text +*.xml text +*.yaml text +*.yml text + +# --- Compiled / binary artefacts --- +*.a binary +*.dll binary +*.dylib binary +*.exe binary +*.gch binary +*.la binary +*.lai binary +*.lib binary +*.lo binary +*.o binary +*.obj binary +*.out binary +*.pch binary +*.slo binary +*.so binary + +# --- Archives / images (common) --- +*.gif binary +*.gz binary +*.ico binary +*.jpeg binary +*.jpg binary +*.png binary +*.tar binary +*.zip binary + +# --- GitHub Linguist --- +**/build/** linguist-generated +**/cmake-build-*/** linguist-generated diff --git a/templates/gitattributes/c_cxx/.gitkeep b/templates/gitattributes/c_cxx/.gitkeep deleted file mode 100644 index e69de29..0000000 diff --git a/templates/gitattributes/cxx/.gitattributes b/templates/gitattributes/cxx/.gitattributes new file mode 100644 index 0000000..66f0c82 --- /dev/null +++ b/templates/gitattributes/cxx/.gitattributes @@ -0,0 +1,99 @@ +# .gitattributes — C++ (GitHub-hosted) +# +# Sources: GitHub Docs (line endings), git-scm gitattributes (diff=cpp), +# gitattributes/gitattributes C++.gitattributes + Common.gitattributes, +# github-linguist overrides. + +# Default: detect text, normalize to LF in the repository +* text=auto + +# --- Source --- +*.c text diff=cpp +*.c++ text diff=cpp +*.cc text diff=cpp +*.cpp text diff=cpp +*.cxx text diff=cpp +*.h text diff=cpp +*.h++ text diff=cpp +*.hh text diff=cpp +*.hpp text diff=cpp +*.hxx text diff=cpp +*.inc text +*.inl text +*.ipp text +*.tcc text +*.tpp text + +# --- Build / config --- +*.am text +*.cmake text +*.m4 text +*.mak text +*.mk text +*akefile text +CMakeLists.txt text +configure text eol=lf +configure.ac text + +# --- Scripts --- +*.bash text eol=lf +*.bat text eol=crlf +*.cmd text eol=crlf +*.ps1 text eol=crlf +*.sh text eol=lf +*.zsh text eol=lf + +# --- Docs / meta --- +*.adoc text +*.markdown text diff=markdown +*.md text diff=markdown +*.txt text +AUTHORS text +CHANGELOG text +CHANGES text +CONTRIBUTING text +COPYING text +LICENSE text +NEWS text +README text +TODO text +.gitattributes text +.gitignore text + +# --- Serialisation --- +*.json text +*.toml text +*.xml text +*.yaml text +*.yml text + +# --- Compiled / binary artefacts --- +*.a binary +*.dll binary +*.dylib binary +*.exe binary +*.gch binary +*.la binary +*.lai binary +*.lib binary +*.lo binary +*.o binary +*.obj binary +*.out binary +*.pch binary +*.slo binary +*.so binary + +# --- Archives / images (common) --- +*.gif binary +*.gz binary +*.ico binary +*.jpeg binary +*.jpg binary +*.png binary +*.tar binary +*.zip binary + +# --- GitHub Linguist --- +**/build/** linguist-generated +**/cmake-build-*/** linguist-generated diff --git a/templates/gitattributes/cxx/.gitkeep b/templates/gitattributes/cxx/.gitkeep deleted file mode 100644 index e69de29..0000000 diff --git a/templates/gitattributes/generic/.gitattributes b/templates/gitattributes/generic/.gitattributes new file mode 100644 index 0000000..d68a24b --- /dev/null +++ b/templates/gitattributes/generic/.gitattributes @@ -0,0 +1,217 @@ +# .gitattributes — generic (union of language templates) +# +# Sources: union of c, cxx, c#, go, javascript, python, ruby, rust, zig +# templates derived from GitHub Docs, git-scm, gitattributes/gitattributes, +# and github-linguist. Prefer a language-specific template when possible. + +# Default: detect text, normalize to LF in the repository +* text=auto + +# --- Source --- +*.c text diff=cpp +*.c++ text diff=cpp +*.cc text diff=cpp +*.cjs text eol=lf +*.cpp text diff=cpp +*.cs text diff=csharp +*.cshtml text diff=html +*.css text diff=css +*.csx text diff=csharp +*.cts text eol=lf +*.cxx text diff=cpp +*.erb text +*.gemspec text eol=lf diff=ruby +*.gemspec.lock text -diff +*.go text eol=lf diff=golang +*.h text diff=cpp +*.h++ text diff=cpp +*.haml text +*.hh text diff=cpp +*.hpp text diff=cpp +*.htm text diff=html +*.html text diff=html +*.hxx text diff=cpp +*.inc text +*.inl text +*.ipp text +*.ipynb text eol=lf +*.js text eol=lf +*.jsx text eol=lf +*.map text -diff +*.mjs text eol=lf +*.mts text eol=lf +*.pxd text diff=python +*.py text eol=lf diff=python +*.py3 text eol=lf diff=python +*.pyi text eol=lf diff=python +*.pyw text eol=lf diff=python +*.pyx text diff=python +*.pyz text diff=python +*.rake text eol=lf diff=ruby +*.razor text diff=html +*.rb text eol=lf diff=ruby +*.rs text eol=lf diff=rust +*.ru text eol=lf diff=ruby +*.s text eol=lf +*.scss text diff=css +*.slim text +*.tcc text +*.tpp text +*.ts text eol=lf +*.tsx text eol=lf +*.vue text eol=lf +*.zig text eol=lf +*.zon text eol=lf +Capfile text eol=lf diff=ruby +Gemfile text eol=lf diff=ruby +Guardfile text eol=lf diff=ruby +Rakefile text eol=lf diff=ruby + +# --- Build / config / lock --- +*.am text +*.cfg text +*.cmake text +*.csproj text eol=crlf +*.fsproj text eol=crlf +*.ini text +*.json text +*.m4 text +*.mak text +*.mk text +*.props text eol=crlf +*.sln text eol=crlf +*.slnx text eol=crlf +*.targets text eol=crlf +*.toml text +*.vbproj text eol=crlf +*.xml text +*.yaml text +*.yml text +*akefile text +.*ignore text +.*rc text +Cargo.lock text +Cargo.toml text +Gemfile.lock text -diff +Pipfile text +Pipfile.lock text -diff +build.zig text eol=lf +build.zig.zon text eol=lf +configure text eol=lf +configure.ac text +go.mod text eol=lf +go.sum text eol=lf +go.work text eol=lf +go.work.sum text eol=lf +package-lock.json text eol=lf -diff +package.json text eol=lf +pnpm-lock.yaml text eol=lf -diff +poetry.lock text -diff +pyproject.toml text +rust-toolchain text +rust-toolchain.toml text +setup.cfg text +setup.py text eol=lf diff=python +yarn.lock text -diff + +# --- Scripts --- +*.bash text eol=lf +*.bat text eol=crlf +*.cmd text eol=crlf +*.ps1 text eol=crlf +*.sh text eol=lf +*.zsh text eol=lf +.husky/* text eol=lf + +# --- Docs / meta --- +*.adoc text +*.markdown text diff=markdown +*.md text diff=markdown +*.txt text +.gitattributes text +.gitignore text +AUTHORS text +CHANGELOG text +CHANGES text +CMakeLists.txt text +CONTRIBUTING text +COPYING text +LICENSE text +NEWS text +README text +TODO text +requirements*.txt text + +# --- Binary / archives / media --- +**/.yarn/plugins/** binary +**/.yarn/releases/** binary +*.a binary +*.db binary +*.dll binary +*.dylib binary +*.eot binary +*.exe binary +*.gch binary +*.gem binary +*.gif binary +*.gz binary +*.ico binary +*.jpeg binary +*.jpg binary +*.la binary +*.lai binary +*.lib binary +*.lo binary +*.nupkg binary +*.o binary +*.obj binary +*.otf binary +*.out binary +*.p binary +*.pch binary +*.pdb binary +*.pickle binary +*.pkl binary +*.png binary +*.pyc binary export-ignore +*.pyd binary +*.pyo binary export-ignore +*.rlib binary +*.slo binary +*.snk binary +*.so binary +*.tar binary +*.test binary +*.ttf binary +*.whl binary +*.woff binary +*.woff2 binary +*.zip binary + +# --- GitHub Linguist --- +**/*.egg-info/** linguist-generated +**/*.min.css linguist-generated +**/*.min.js linguist-generated +**/.mypy_cache/** linguist-generated +**/.pytest_cache/** linguist-generated +**/.ruff_cache/** linguist-generated +**/.zig-cache/** linguist-generated +**/__pycache__/** linguist-generated +**/bin/** linguist-generated +**/build/** linguist-generated +**/cmake-build-*/** linguist-generated +**/coverage/** linguist-generated +**/dist/** linguist-generated +**/doc/** linguist-documentation +**/node_modules/** linguist-vendored +**/obj/** linguist-generated +**/packages/** linguist-vendored +**/pkg/** linguist-generated +**/target/** linguist-generated +**/vendor/** linguist-vendored +**/vendor/bundle/** linguist-vendored +**/vendor/cache/** linguist-vendored +**/zig-cache/** linguist-generated +**/zig-out/** linguist-generated +jsconfig.json text linguist-language=JSON-with-Comments +tsconfig.json text linguist-language=JSON-with-Comments diff --git a/templates/gitattributes/generic/.gitkeep b/templates/gitattributes/generic/.gitkeep deleted file mode 100644 index e69de29..0000000 diff --git a/templates/gitattributes/go/.gitattributes b/templates/gitattributes/go/.gitattributes new file mode 100644 index 0000000..0913bd6 --- /dev/null +++ b/templates/gitattributes/go/.gitattributes @@ -0,0 +1,67 @@ +# .gitattributes — Go (GitHub-hosted) +# +# Sources: GitHub Docs (line endings), git-scm gitattributes (diff=golang), +# modern Go GitHub practice (*.go text eol=lf; contrast: golang/go uses -text), +# github-linguist overrides. + +# Default: detect text, normalize to LF in the repository +* text=auto + +# --- Source (LF required; avoids gofmt churn on Windows) --- +*.go text eol=lf diff=golang +*.s text eol=lf +go.mod text eol=lf +go.sum text eol=lf +go.work text eol=lf +go.work.sum text eol=lf + +# --- Scripts --- +*.bash text eol=lf +*.bat text eol=crlf +*.cmd text eol=crlf +*.ps1 text eol=crlf +*.sh text eol=lf +*.zsh text eol=lf + +# --- Docs / meta --- +*.adoc text +*.markdown text diff=markdown +*.md text diff=markdown +*.txt text +AUTHORS text +CHANGELOG text +CHANGES text +CONTRIBUTING text +COPYING text +LICENSE text +NEWS text +README text +TODO text +.gitattributes text +.gitignore text + +# --- Serialisation --- +*.json text +*.toml text +*.xml text +*.yaml text +*.yml text + +# --- Binary --- +*.a binary +*.exe binary +*.so binary +*.test binary + +# --- Archives / images (common) --- +*.gif binary +*.gz binary +*.ico binary +*.jpeg binary +*.jpg binary +*.png binary +*.tar binary +*.zip binary + +# --- GitHub Linguist --- +**/vendor/** linguist-vendored diff --git a/templates/gitattributes/go/.gitkeep b/templates/gitattributes/go/.gitkeep deleted file mode 100644 index e69de29..0000000 diff --git a/templates/gitattributes/javascript/.gitattributes b/templates/gitattributes/javascript/.gitattributes new file mode 100644 index 0000000..b575d48 --- /dev/null +++ b/templates/gitattributes/javascript/.gitattributes @@ -0,0 +1,89 @@ +# .gitattributes — JavaScript / TypeScript (GitHub-hosted) +# +# Sources: GitHub Docs (line endings), gitattributes/gitattributes Web.gitattributes, +# github-linguist overrides (generated / vendored / JSON-with-Comments). + +# Default: detect text, normalize to LF in the repository +* text=auto + +# --- Source --- +*.cjs text eol=lf +*.css text diff=css +*.cts text eol=lf +*.htm text diff=html +*.html text diff=html +*.js text eol=lf +*.jsx text eol=lf +*.mjs text eol=lf +*.mts text eol=lf +*.scss text diff=css +*.ts text eol=lf +*.tsx text eol=lf +*.vue text eol=lf + +# --- Lockfiles / maps (text but hide noisy diffs) --- +*.map text -diff +package-lock.json text eol=lf -diff +pnpm-lock.yaml text eol=lf -diff +yarn.lock text -diff + +# --- Config --- +*.json text +*.toml text +*.yaml text +*.yml text +.*rc text +.*ignore text +package.json text eol=lf +tsconfig.json text linguist-language=JSON-with-Comments +jsconfig.json text linguist-language=JSON-with-Comments + +# --- Scripts --- +*.bash text eol=lf +*.bat text eol=crlf +*.cmd text eol=crlf +*.ps1 text eol=crlf +*.sh text eol=lf +*.zsh text eol=lf +.husky/* text eol=lf + +# --- Docs / meta --- +*.adoc text +*.markdown text diff=markdown +*.md text diff=markdown +*.txt text +AUTHORS text +CHANGELOG text +CHANGES text +CONTRIBUTING text +COPYING text +LICENSE text +NEWS text +README text +TODO text +.gitattributes text +.gitignore text + +# --- Binary / fonts / media --- +*.eot binary +*.gif binary +*.gz binary +*.ico binary +*.jpeg binary +*.jpg binary +*.otf binary +*.png binary +*.tar binary +*.ttf binary +*.woff binary +*.woff2 binary +*.zip binary + +# --- GitHub Linguist --- +**/*.min.css linguist-generated +**/*.min.js linguist-generated +**/dist/** linguist-generated +**/build/** linguist-generated +**/node_modules/** linguist-vendored +**/.yarn/releases/** binary +**/.yarn/plugins/** binary diff --git a/templates/gitattributes/javascript/.gitkeep b/templates/gitattributes/javascript/.gitkeep deleted file mode 100644 index e69de29..0000000 diff --git a/templates/gitattributes/python/.gitattributes b/templates/gitattributes/python/.gitattributes new file mode 100644 index 0000000..f4e3751 --- /dev/null +++ b/templates/gitattributes/python/.gitattributes @@ -0,0 +1,90 @@ +# .gitattributes — Python (GitHub-hosted) +# +# Sources: GitHub Docs (line endings), git-scm gitattributes (diff=python), +# gitattributes/gitattributes Python.gitattributes + Common.gitattributes, +# github-linguist overrides. + +# Default: detect text, normalize to LF in the repository +* text=auto + +# --- Source --- +*.pxd text diff=python +*.py text eol=lf diff=python +*.py3 text eol=lf diff=python +*.pyi text eol=lf diff=python +*.pyx text diff=python +*.pyw text eol=lf diff=python +*.pyz text diff=python +*.ipynb text eol=lf + +# --- Config / lock --- +*.cfg text +*.ini text +*.toml text +Pipfile text +Pipfile.lock text -diff +poetry.lock text -diff +pyproject.toml text +requirements*.txt text +setup.cfg text +setup.py text eol=lf diff=python + +# --- Scripts --- +*.bash text eol=lf +*.bat text eol=crlf +*.cmd text eol=crlf +*.ps1 text eol=crlf +*.sh text eol=lf +*.zsh text eol=lf + +# --- Docs / meta --- +*.adoc text +*.markdown text diff=markdown +*.md text diff=markdown +*.txt text +AUTHORS text +CHANGELOG text +CHANGES text +CONTRIBUTING text +COPYING text +LICENSE text +NEWS text +README text +TODO text +.gitattributes text +.gitignore text + +# --- Serialisation --- +*.json text +*.xml text +*.yaml text +*.yml text + +# --- Binary / bytecode --- +*.db binary +*.p binary +*.pickle binary +*.pkl binary +*.pyc binary export-ignore +*.pyd binary +*.pyo binary export-ignore +*.so binary +*.whl binary + +# --- Archives / images (common) --- +*.gif binary +*.gz binary +*.ico binary +*.jpeg binary +*.jpg binary +*.png binary +*.tar binary +*.zip binary + +# --- GitHub Linguist --- +**/__pycache__/** linguist-generated +**/.mypy_cache/** linguist-generated +**/.pytest_cache/** linguist-generated +**/.ruff_cache/** linguist-generated +**/dist/** linguist-generated +**/*.egg-info/** linguist-generated diff --git a/templates/gitattributes/python/.gitkeep b/templates/gitattributes/python/.gitkeep deleted file mode 100644 index e69de29..0000000 diff --git a/templates/gitattributes/ruby/.gitattributes b/templates/gitattributes/ruby/.gitattributes new file mode 100644 index 0000000..702382f --- /dev/null +++ b/templates/gitattributes/ruby/.gitattributes @@ -0,0 +1,75 @@ +# .gitattributes — Ruby (GitHub-hosted) +# +# Sources: GitHub Docs (line endings), git-scm gitattributes (diff=ruby), +# gitattributes/gitattributes Common.gitattributes + Web (*.rb), +# github-linguist overrides. + +# Default: detect text, normalize to LF in the repository +* text=auto + +# --- Source --- +*.gemspec text eol=lf diff=ruby +*.rake text eol=lf diff=ruby +*.rb text eol=lf diff=ruby +*.ru text eol=lf diff=ruby +Gemfile text eol=lf diff=ruby +Rakefile text eol=lf diff=ruby +Capfile text eol=lf diff=ruby +Guardfile text eol=lf diff=ruby +*.erb text +*.haml text +*.slim text + +# --- Lock / config --- +Gemfile.lock text -diff +*.gemspec.lock text -diff +*.yml text +*.yaml text +*.toml text +*.json text + +# --- Scripts --- +*.bash text eol=lf +*.bat text eol=crlf +*.cmd text eol=crlf +*.ps1 text eol=crlf +*.sh text eol=lf +*.zsh text eol=lf + +# --- Docs / meta --- +*.adoc text +*.markdown text diff=markdown +*.md text diff=markdown +*.txt text +AUTHORS text +CHANGELOG text +CHANGES text +CONTRIBUTING text +COPYING text +LICENSE text +NEWS text +README text +TODO text +.gitattributes text +.gitignore text + +# --- Binary --- +*.gem binary +*.so binary + +# --- Archives / images (common) --- +*.gif binary +*.gz binary +*.ico binary +*.jpeg binary +*.jpg binary +*.png binary +*.tar binary +*.zip binary + +# --- GitHub Linguist --- +**/vendor/bundle/** linguist-vendored +**/vendor/cache/** linguist-vendored +**/coverage/** linguist-generated +**/doc/** linguist-documentation +**/pkg/** linguist-generated diff --git a/templates/gitattributes/ruby/.gitkeep b/templates/gitattributes/ruby/.gitkeep deleted file mode 100644 index e69de29..0000000 diff --git a/templates/gitattributes/rust/.gitattributes b/templates/gitattributes/rust/.gitattributes new file mode 100644 index 0000000..5a8705b --- /dev/null +++ b/templates/gitattributes/rust/.gitattributes @@ -0,0 +1,68 @@ +# .gitattributes — Rust (GitHub-hosted) +# +# Sources: GitHub Docs (line endings), git-scm gitattributes (diff=rust), +# gitattributes/gitattributes Rust.gitattributes + Common.gitattributes, +# github-linguist overrides. + +# Default: detect text, normalize to LF in the repository +* text=auto + +# --- Source --- +*.rs text eol=lf diff=rust +*.toml text +Cargo.lock text +Cargo.toml text +rust-toolchain text +rust-toolchain.toml text + +# --- Scripts --- +*.bash text eol=lf +*.bat text eol=crlf +*.cmd text eol=crlf +*.ps1 text eol=crlf +*.sh text eol=lf +*.zsh text eol=lf + +# --- Docs / meta --- +*.adoc text +*.markdown text diff=markdown +*.md text diff=markdown +*.txt text +AUTHORS text +CHANGELOG text +CHANGES text +CONTRIBUTING text +COPYING text +LICENSE text +NEWS text +README text +TODO text +.gitattributes text +.gitignore text + +# --- Serialisation --- +*.json text +*.xml text +*.yaml text +*.yml text + +# --- Binary --- +*.a binary +*.dll binary +*.dylib binary +*.exe binary +*.rlib binary +*.so binary + +# --- Archives / images (common) --- +*.gif binary +*.gz binary +*.ico binary +*.jpeg binary +*.jpg binary +*.png binary +*.tar binary +*.zip binary + +# --- GitHub Linguist --- +**/target/** linguist-generated diff --git a/templates/gitattributes/rust/.gitkeep b/templates/gitattributes/rust/.gitkeep deleted file mode 100644 index e69de29..0000000 diff --git a/templates/gitattributes/zig/.gitattributes b/templates/gitattributes/zig/.gitattributes new file mode 100644 index 0000000..b6d4b9c --- /dev/null +++ b/templates/gitattributes/zig/.gitattributes @@ -0,0 +1,68 @@ +# .gitattributes — Zig (GitHub-hosted) +# +# Sources: GitHub Docs (line endings), git-scm gitattributes (no built-in +# zig diff driver), ziglang conventions for artefacts, github-linguist overrides. + +# Default: detect text, normalize to LF in the repository +* text=auto + +# --- Source --- +*.zig text eol=lf +*.zon text eol=lf +build.zig text eol=lf +build.zig.zon text eol=lf + +# --- Scripts --- +*.bash text eol=lf +*.bat text eol=crlf +*.cmd text eol=crlf +*.ps1 text eol=crlf +*.sh text eol=lf +*.zsh text eol=lf + +# --- Docs / meta --- +*.adoc text +*.markdown text diff=markdown +*.md text diff=markdown +*.txt text +AUTHORS text +CHANGELOG text +CHANGES text +CONTRIBUTING text +COPYING text +LICENSE text +NEWS text +README text +TODO text +.gitattributes text +.gitignore text + +# --- Serialisation --- +*.json text +*.toml text +*.xml text +*.yaml text +*.yml text + +# --- Binary --- +*.a binary +*.exe binary +*.o binary +*.obj binary +*.so binary + +# --- Archives / images (common) --- +*.gif binary +*.gz binary +*.ico binary +*.jpeg binary +*.jpg binary +*.png binary +*.tar binary +*.zip binary + +# --- GitHub Linguist --- +# Prefer .gitignore for these; mark if ever committed +**/.zig-cache/** linguist-generated +**/zig-cache/** linguist-generated +**/zig-out/** linguist-generated diff --git a/templates/gitattributes/zig/.gitkeep b/templates/gitattributes/zig/.gitkeep deleted file mode 100644 index e69de29..0000000 diff --git a/templates/gitignore/README.md b/templates/gitignore/README.md index 5687149..8fea902 100644 --- a/templates/gitignore/README.md +++ b/templates/gitignore/README.md @@ -3,22 +3,22 @@ Drop-in root **`.gitignore`** files, organised by primary language. -**Status:** Phase 0 — layout only (**`.gitkeep`** placeholders). Content lands in a later phase. +**Status:** Phase 2 — populated (lean Synesis-header consensus from freelibs exemplars; not a dump of every historical project ignore). ## Table of Contents -- [How to use (once populated)](#how-to-use-once-populated) +- [How to use](#how-to-use) - [Layout](#layout) -## How to use (once populated) +## How to use ```sh cp templates/gitignore//.gitignore /path/to/repo/.gitignore ``` -Prefer the language-specific template that matches the project’s primary language; use **generic** only for multi-language trees. +Prefer the language-specific template that matches the project’s primary language; use **generic** only for multi-language trees. Projects may still add local paths after copying. ## Layout diff --git a/templates/gitignore/c#/.gitignore b/templates/gitignore/c#/.gitignore new file mode 100644 index 0000000..2ef429f --- /dev/null +++ b/templates/gitignore/c#/.gitignore @@ -0,0 +1,40 @@ +# Synesis Information Systems .gitignore for .NET / C# libraries + + +# directories (by name) + +/.idea/ +/.vs/ +/TestResults/ +/artifacts/ +/bin/ +/obj/ +/scratch/ +[Bb]in/ +[Oo]bj/ + + +# directories (by pattern) + +**/[Pp]ackages/* + + +# files (by name) + +.DS_Store + + +# files (by pattern) + +*~ +*.coverage +*.coveragexml +*.nupkg +*.snupkg +*.suo +*.sw[pon] +*.tmp +*.trx +*.user +*.zip +project.lock.json diff --git a/templates/gitignore/c#/.gitkeep b/templates/gitignore/c#/.gitkeep deleted file mode 100644 index e69de29..0000000 diff --git a/templates/gitignore/c/.gitignore b/templates/gitignore/c/.gitignore new file mode 100644 index 0000000..32b2561 --- /dev/null +++ b/templates/gitignore/c/.gitignore @@ -0,0 +1,46 @@ +# Synesis Information Systems .gitignore for C libraries + + +# directories (by name) + +/.idea/ +/.vs/ +/_analyses/ +/_build/ +/_build-ci/ +/bin/ +/ipch/ +/lib/ +/scratch/ +/target/ +bin/ +ipch/ +lib/ + + +# directories (by pattern) + + +# files (by name) + +.DS_Store + + +# files (by pattern) + +*~ +*.a +*.dll +*.dylib +*.exe +*.gch +*.lib +*.o +*.obj +*.out +*.pch +*.pdb +*.so +*.sw[ponm] +*.tmp +*.zip diff --git a/templates/gitignore/c/.gitkeep b/templates/gitignore/c/.gitkeep deleted file mode 100644 index e69de29..0000000 diff --git a/templates/gitignore/c_cxx/.gitignore b/templates/gitignore/c_cxx/.gitignore new file mode 100644 index 0000000..8b69d23 --- /dev/null +++ b/templates/gitignore/c_cxx/.gitignore @@ -0,0 +1,46 @@ +# Synesis Information Systems .gitignore for C / C++ libraries + + +# directories (by name) + +/.idea/ +/.vs/ +/_analyses/ +/_build/ +/_build-ci/ +/bin/ +/ipch/ +/lib/ +/scratch/ +/target/ +bin/ +ipch/ +lib/ + + +# directories (by pattern) + + +# files (by name) + +.DS_Store + + +# files (by pattern) + +*~ +*.a +*.dll +*.dylib +*.exe +*.gch +*.lib +*.o +*.obj +*.out +*.pch +*.pdb +*.so +*.sw[ponm] +*.tmp +*.zip diff --git a/templates/gitignore/c_cxx/.gitkeep b/templates/gitignore/c_cxx/.gitkeep deleted file mode 100644 index e69de29..0000000 diff --git a/templates/gitignore/cxx/.gitignore b/templates/gitignore/cxx/.gitignore new file mode 100644 index 0000000..3ee81f9 --- /dev/null +++ b/templates/gitignore/cxx/.gitignore @@ -0,0 +1,46 @@ +# Synesis Information Systems .gitignore for C++ libraries + + +# directories (by name) + +/.idea/ +/.vs/ +/_analyses/ +/_build/ +/_build-ci/ +/bin/ +/ipch/ +/lib/ +/scratch/ +/target/ +bin/ +ipch/ +lib/ + + +# directories (by pattern) + + +# files (by name) + +.DS_Store + + +# files (by pattern) + +*~ +*.a +*.dll +*.dylib +*.exe +*.gch +*.lib +*.o +*.obj +*.out +*.pch +*.pdb +*.so +*.sw[ponm] +*.tmp +*.zip diff --git a/templates/gitignore/cxx/.gitkeep b/templates/gitignore/cxx/.gitkeep deleted file mode 100644 index e69de29..0000000 diff --git a/templates/gitignore/generic/.gitignore b/templates/gitignore/generic/.gitignore new file mode 100644 index 0000000..34e32d3 --- /dev/null +++ b/templates/gitignore/generic/.gitignore @@ -0,0 +1,38 @@ +# Synesis Information Systems .gitignore for mixed-language / generic trees + + +# directories (by name) + +/.idea/ +/.venv/ +/.vs/ +/build/ +/coverage/ +/dist/ +/node_modules/ +/scratch/ +/target/ +/tmp/ + + +# directories (by pattern) + +**/__pycache__/ + + +# files (by name) + +.DS_Store + + +# files (by pattern) + +*~ +*.dll +*.dylib +*.exe +*.o +*.so +*.sw[ponm] +*.tmp +*.zip diff --git a/templates/gitignore/generic/.gitkeep b/templates/gitignore/generic/.gitkeep deleted file mode 100644 index e69de29..0000000 diff --git a/templates/gitignore/go/.gitignore b/templates/gitignore/go/.gitignore new file mode 100644 index 0000000..bebf8c8 --- /dev/null +++ b/templates/gitignore/go/.gitignore @@ -0,0 +1,33 @@ +# Synesis Information Systems .gitignore for Go libraries + + +# directories (by name) + +/scratch/ + + +# directories (by pattern) + + +# files (by name) + +.DS_Store + + +# files (by pattern) + +*~ +*.[568vq] +*.a +*.dll +*.dylib +*.exe +*.lib +*.o +*.out +*.prof +*.so +*.sw[pon] +*.test +*.tmp +*.zip diff --git a/templates/gitignore/go/.gitkeep b/templates/gitignore/go/.gitkeep deleted file mode 100644 index e69de29..0000000 diff --git a/templates/gitignore/javascript/.gitignore b/templates/gitignore/javascript/.gitignore new file mode 100644 index 0000000..8251437 --- /dev/null +++ b/templates/gitignore/javascript/.gitignore @@ -0,0 +1,28 @@ +# Synesis Information Systems .gitignore for JavaScript libraries + + +# directories (by name) + +/coverage/ +/node_modules/ +/scratch/ + + +# directories (by pattern) + + +# files (by name) + +.DS_Store + + +# files (by pattern) + +*~ +*.sw[pon] +*.tgz +*.tmp +*.zip +npm-debug.log* +yarn-debug.log* +yarn-error.log* diff --git a/templates/gitignore/javascript/.gitkeep b/templates/gitignore/javascript/.gitkeep deleted file mode 100644 index e69de29..0000000 diff --git a/templates/gitignore/python/.gitignore b/templates/gitignore/python/.gitignore new file mode 100644 index 0000000..111556a --- /dev/null +++ b/templates/gitignore/python/.gitignore @@ -0,0 +1,33 @@ +# Synesis Information Systems .gitignore for Python libraries + + +# directories (by name) + +/.pytest_cache/ +/.ruff_cache/ +/.venv/ +/build/ +/dist/ +/scratch/ + +*.egg-info/ + + +# directories (by pattern) + +**/__pycache__/ + + +# files (by name) + +.DS_Store + + +# files (by pattern) + +*~ +*.pyc +*.pyo +*.sw[pon] +*.tmp +*.zip diff --git a/templates/gitignore/python/.gitkeep b/templates/gitignore/python/.gitkeep deleted file mode 100644 index e69de29..0000000 diff --git a/templates/gitignore/ruby/.gitignore b/templates/gitignore/ruby/.gitignore new file mode 100644 index 0000000..08c9fb4 --- /dev/null +++ b/templates/gitignore/ruby/.gitignore @@ -0,0 +1,35 @@ +# Synesis Information Systems .gitignore for Ruby gems + + +# directories (by name) + +/.bundle/ +/.yardoc/ +/_yardoc/ +/coverage/ +/doc/ +/pkg/ +/rdoc/ +/scratch/ +/tmp/ +/vendor/bundle/ + + +# directories (by pattern) + + +# files (by name) + +.DS_Store +.ruby-version +Gemfile.lock + + +# files (by pattern) + +*~ +*.gem +*.rbc +*.sw[pon] +*.tmp +*.zip diff --git a/templates/gitignore/ruby/.gitkeep b/templates/gitignore/ruby/.gitkeep deleted file mode 100644 index e69de29..0000000 diff --git a/templates/gitignore/rust/.gitignore b/templates/gitignore/rust/.gitignore new file mode 100644 index 0000000..29afc59 --- /dev/null +++ b/templates/gitignore/rust/.gitignore @@ -0,0 +1,27 @@ +# Synesis Information Systems .gitignore for Rust crates + + +# directories (by name) + +/.idea/ +/scratch/ +/target/ + + +# directories (by pattern) + +**/__pycache__/ + + +# files (by name) + +.DS_Store + + +# files (by pattern) + +**/*.rs.bk +*~ +*.sw[ponm] +*.tmp +*.zip diff --git a/templates/gitignore/rust/.gitkeep b/templates/gitignore/rust/.gitkeep deleted file mode 100644 index e69de29..0000000 diff --git a/templates/gitignore/zig/.gitignore b/templates/gitignore/zig/.gitignore new file mode 100644 index 0000000..d14c0b1 --- /dev/null +++ b/templates/gitignore/zig/.gitignore @@ -0,0 +1,24 @@ +# Synesis Information Systems .gitignore for Zig projects + + +# directories (by name) + +/.zig-cache/ +/scratch/ +/zig-out/ + + +# directories (by pattern) + + +# files (by name) + +.DS_Store + + +# files (by pattern) + +*~ +*.sw[pon] +*.tmp +*.zip diff --git a/templates/gitignore/zig/.gitkeep b/templates/gitignore/zig/.gitkeep deleted file mode 100644 index e69de29..0000000 diff --git a/templates/vimrc/README.md b/templates/vimrc/README.md index 2b6ec51..a81e5ed 100644 --- a/templates/vimrc/README.md +++ b/templates/vimrc/README.md @@ -3,22 +3,22 @@ Drop-in root **`.vimrc`** files, organised by primary language. -**Status:** Phase 0 layout plus early Phase 1 seed — **`c_cxx/.vimrc`** holds the preserved Synesis C/C++ gold (moved out of this repository’s root self **`.vimrc`**). Other language directories remain **`.gitkeep`** placeholders until Phase 2. Do **not** treat this repository’s root **`.vimrc`** as a consumer template — that file is **self** boilerplate for **misc-dev-scripts**. +**Status:** Phase 2 — populated from freelibs language gold (**c** / **cxx** / **c_cxx**, **go**, **python**, **ruby**, **rust**, **c#**, **zig**) plus synthesized **javascript** and **generic**. Do **not** treat this repository’s root **`.vimrc`** as a consumer template — that file is **self** boilerplate for **misc-dev-scripts**. ## Table of Contents -- [How to use (once populated)](#how-to-use-once-populated) +- [How to use](#how-to-use) - [Layout](#layout) -## How to use (once populated) +## How to use ```sh cp templates/vimrc//.vimrc /path/to/repo/.vimrc ``` -Prefer the language-specific template that matches the project’s primary language; use **generic** only for multi-language trees. Until Phase 2 completes other languages, **`c_cxx`** is the only seeded consumer template here. +Prefer the language-specific template that matches the project’s primary language; use **generic** only for multi-language trees. ## Layout @@ -27,7 +27,7 @@ Prefer the language-specific template that matches the project’s primary langu | --- | --- | | **c/** | C-primary | | **c#/** | C# / .NET | -| **c_cxx/** | Mixed C / C++ (**seeded** — Synesis C/C++ gold) | +| **c_cxx/** | Mixed C / C++ | | **cxx/** | C++-primary | | **generic/** | Union / mixed | | **go/** | Go | diff --git a/templates/vimrc/c#/.gitkeep b/templates/vimrc/c#/.gitkeep deleted file mode 100644 index e69de29..0000000 diff --git a/templates/vimrc/c#/.vimrc b/templates/vimrc/c#/.vimrc new file mode 100644 index 0000000..b494c05 --- /dev/null +++ b/templates/vimrc/c#/.vimrc @@ -0,0 +1,66 @@ +" Synesis .NET project .vimrc — aligned with .vscode/settings.json (C#) + +set nocompatible +filetype indent plugin on +syntax enable +set autoindent +set backspace=indent,eol,start +set hlsearch +set incsearch +set number + +" files.insertFinalNewline +set eol +set fixeol + +" editor.renderWhitespace: all +set list +set listchars=tab:->,trail:-,extends:>,precedes:<,nbsp:+ + +" editor.detectIndentation: false — global defaults match [csharp] (editor.tabSize: 4, insertSpaces: true, rulers: [76]) +set colorcolumn=76 +set expandtab +set shiftwidth=4 +set softtabstop=4 +set tabstop=4 + +" colorcolumn draws a full-column tint in Vim (not a VS Code-style 1px line). +" Keep it subtle via the ColorColumn highlight group; reapply after colorscheme changes. +if has('termguicolors') + " set termguicolors +endif + +function! s:ConfigureColorColumn() abort + highlight ColorColumn ctermbg=236 guibg=#2a2a2a cterm=NONE gui=NONE +endfunction + +call s:ConfigureColorColumn() +autocmd ColorScheme * call s:ConfigureColorColumn() + +" files.trimTrailingWhitespace +autocmd BufWritePre * %s/\s\+$//e + +augroup sis_dotnet + autocmd! + " [bat] / [dosbatch] + autocmd FileType bat,dosbatch setlocal expandtab tabstop=4 shiftwidth=4 softtabstop=4 colorcolumn=60,76 + + " [csharp] — match .vscode [csharp] tabSize 4 / insertSpaces true / rulers 76 + autocmd FileType cs,csx setlocal expandtab tabstop=4 shiftwidth=4 softtabstop=4 colorcolumn=76 + + " [json] / [markdown] / [yaml] + autocmd FileType json,markdown,yaml setlocal expandtab tabstop=2 shiftwidth=2 softtabstop=2 + + " [python] + autocmd FileType python setlocal expandtab tabstop=4 shiftwidth=4 softtabstop=4 colorcolumn=60,76 + + " [shellscript] + autocmd FileType bash,sh,zsh setlocal expandtab tabstop=2 shiftwidth=2 softtabstop=2 colorcolumn=60,76 + + " [toml] + autocmd FileType toml setlocal noexpandtab tabstop=2 shiftwidth=2 softtabstop=2 + + " [xml] — SDK-style .csproj / .props / .targets use 2-space indent + autocmd FileType xml setlocal expandtab tabstop=2 shiftwidth=2 softtabstop=2 + +augroup END diff --git a/templates/vimrc/c/.gitkeep b/templates/vimrc/c/.gitkeep deleted file mode 100644 index e69de29..0000000 diff --git a/templates/vimrc/c/.vimrc b/templates/vimrc/c/.vimrc new file mode 100644 index 0000000..cebe6af --- /dev/null +++ b/templates/vimrc/c/.vimrc @@ -0,0 +1,70 @@ +" Synesis C/C++ project .vimrc — aligned with .sis/.vscode/c_cxx/settings.json + +set nocompatible +filetype indent plugin on +syntax enable +set autoindent +set backspace=indent,eol,start +set hlsearch +set incsearch +set number + +" files.insertFinalNewline +set eol +set fixeol + +" editor.renderWhitespace: all +set list +set listchars=tab:->,trail:-,extends:>,precedes:<,nbsp:+ + +" editor.detectIndentation: false — global defaults (editor.tabSize: 4, insertSpaces: true) +set colorcolumn=76 +set expandtab +set shiftwidth=4 +set softtabstop=4 +set tabstop=4 + +" colorcolumn draws a full-column tint in Vim (not a VS Code-style 1px line). +" Keep it subtle via the ColorColumn highlight group; reapply after colorscheme changes. +if has('termguicolors') + " set termguicolors +endif + +function! s:ConfigureColorColumn() abort + highlight ColorColumn ctermbg=236 guibg=#2a2a2a cterm=NONE gui=NONE +endfunction + +call s:ConfigureColorColumn() +autocmd ColorScheme * call s:ConfigureColorColumn() + +" files.trimTrailingWhitespace +autocmd BufWritePre * %s/\s\+$//e + +augroup sis_c_cxx + autocmd! + " [bat] + autocmd FileType bat,dosbatch setlocal expandtab tabstop=4 shiftwidth=4 softtabstop=4 colorcolumn=60,76 + + " [c] / [cpp] + autocmd FileType c,cpp setlocal expandtab tabstop=4 shiftwidth=4 softtabstop=4 colorcolumn=60,64,68,72,76 + + " [cmake] + autocmd FileType cmake setlocal noexpandtab tabstop=4 shiftwidth=4 softtabstop=4 + + " [json] / [markdown] / [ruby] / [yaml] + autocmd FileType json,markdown,ruby,yaml setlocal expandtab tabstop=2 shiftwidth=2 softtabstop=2 + + " [python] + autocmd FileType python setlocal expandtab tabstop=4 shiftwidth=4 softtabstop=4 colorcolumn=60,76 + + " [rust] + autocmd FileType rs setlocal expandtab tabstop=4 shiftwidth=4 softtabstop=4 colorcolumn=76 + + " [shellscript] + autocmd FileType bash,sh,zsh setlocal expandtab tabstop=2 shiftwidth=2 softtabstop=2 colorcolumn=60,76 + + " [toml] + autocmd FileType toml setlocal noexpandtab tabstop=2 shiftwidth=2 softtabstop=2 + +augroup END + diff --git a/templates/vimrc/c_cxx/.vimrc b/templates/vimrc/c_cxx/.vimrc index 23ab392..cebe6af 100644 --- a/templates/vimrc/c_cxx/.vimrc +++ b/templates/vimrc/c_cxx/.vimrc @@ -42,18 +42,17 @@ autocmd BufWritePre * %s/\s\+$//e augroup sis_c_cxx autocmd! - " [bat] autocmd FileType bat,dosbatch setlocal expandtab tabstop=4 shiftwidth=4 softtabstop=4 colorcolumn=60,76 - " [cmake] - autocmd FileType cmake setlocal noexpandtab tabstop=4 shiftwidth=4 softtabstop=4 - " [c] / [cpp] autocmd FileType c,cpp setlocal expandtab tabstop=4 shiftwidth=4 softtabstop=4 colorcolumn=60,64,68,72,76 - " [json] / [markdown] / [yaml] / [ruby] - autocmd FileType json,markdown,yaml,ruby setlocal expandtab tabstop=2 shiftwidth=2 softtabstop=2 + " [cmake] + autocmd FileType cmake setlocal noexpandtab tabstop=4 shiftwidth=4 softtabstop=4 + + " [json] / [markdown] / [ruby] / [yaml] + autocmd FileType json,markdown,ruby,yaml setlocal expandtab tabstop=2 shiftwidth=2 softtabstop=2 " [python] autocmd FileType python setlocal expandtab tabstop=4 shiftwidth=4 softtabstop=4 colorcolumn=60,76 @@ -62,9 +61,10 @@ augroup sis_c_cxx autocmd FileType rs setlocal expandtab tabstop=4 shiftwidth=4 softtabstop=4 colorcolumn=76 " [shellscript] - autocmd FileType sh,bash,zsh setlocal expandtab tabstop=2 shiftwidth=2 softtabstop=2 colorcolumn=60,76 + autocmd FileType bash,sh,zsh setlocal expandtab tabstop=2 shiftwidth=2 softtabstop=2 colorcolumn=60,76 " [toml] autocmd FileType toml setlocal noexpandtab tabstop=2 shiftwidth=2 softtabstop=2 + augroup END diff --git a/templates/vimrc/cxx/.gitkeep b/templates/vimrc/cxx/.gitkeep deleted file mode 100644 index e69de29..0000000 diff --git a/templates/vimrc/cxx/.vimrc b/templates/vimrc/cxx/.vimrc new file mode 100644 index 0000000..cebe6af --- /dev/null +++ b/templates/vimrc/cxx/.vimrc @@ -0,0 +1,70 @@ +" Synesis C/C++ project .vimrc — aligned with .sis/.vscode/c_cxx/settings.json + +set nocompatible +filetype indent plugin on +syntax enable +set autoindent +set backspace=indent,eol,start +set hlsearch +set incsearch +set number + +" files.insertFinalNewline +set eol +set fixeol + +" editor.renderWhitespace: all +set list +set listchars=tab:->,trail:-,extends:>,precedes:<,nbsp:+ + +" editor.detectIndentation: false — global defaults (editor.tabSize: 4, insertSpaces: true) +set colorcolumn=76 +set expandtab +set shiftwidth=4 +set softtabstop=4 +set tabstop=4 + +" colorcolumn draws a full-column tint in Vim (not a VS Code-style 1px line). +" Keep it subtle via the ColorColumn highlight group; reapply after colorscheme changes. +if has('termguicolors') + " set termguicolors +endif + +function! s:ConfigureColorColumn() abort + highlight ColorColumn ctermbg=236 guibg=#2a2a2a cterm=NONE gui=NONE +endfunction + +call s:ConfigureColorColumn() +autocmd ColorScheme * call s:ConfigureColorColumn() + +" files.trimTrailingWhitespace +autocmd BufWritePre * %s/\s\+$//e + +augroup sis_c_cxx + autocmd! + " [bat] + autocmd FileType bat,dosbatch setlocal expandtab tabstop=4 shiftwidth=4 softtabstop=4 colorcolumn=60,76 + + " [c] / [cpp] + autocmd FileType c,cpp setlocal expandtab tabstop=4 shiftwidth=4 softtabstop=4 colorcolumn=60,64,68,72,76 + + " [cmake] + autocmd FileType cmake setlocal noexpandtab tabstop=4 shiftwidth=4 softtabstop=4 + + " [json] / [markdown] / [ruby] / [yaml] + autocmd FileType json,markdown,ruby,yaml setlocal expandtab tabstop=2 shiftwidth=2 softtabstop=2 + + " [python] + autocmd FileType python setlocal expandtab tabstop=4 shiftwidth=4 softtabstop=4 colorcolumn=60,76 + + " [rust] + autocmd FileType rs setlocal expandtab tabstop=4 shiftwidth=4 softtabstop=4 colorcolumn=76 + + " [shellscript] + autocmd FileType bash,sh,zsh setlocal expandtab tabstop=2 shiftwidth=2 softtabstop=2 colorcolumn=60,76 + + " [toml] + autocmd FileType toml setlocal noexpandtab tabstop=2 shiftwidth=2 softtabstop=2 + +augroup END + diff --git a/templates/vimrc/generic/.gitkeep b/templates/vimrc/generic/.gitkeep deleted file mode 100644 index e69de29..0000000 diff --git a/templates/vimrc/generic/.vimrc b/templates/vimrc/generic/.vimrc new file mode 100644 index 0000000..9843fdf --- /dev/null +++ b/templates/vimrc/generic/.vimrc @@ -0,0 +1,82 @@ +" Synesis generic / mixed-language project .vimrc — aligned with +" .vscode/settings.json (generic union defaults) + +set nocompatible +filetype indent plugin on +syntax enable +set autoindent +set backspace=indent,eol,start +set hlsearch +set incsearch +set number + +" files.insertFinalNewline +set eol +set fixeol + +" editor.renderWhitespace: all +set list +set listchars=tab:->,trail:-,extends:>,precedes:<,nbsp:+ + +" editor.detectIndentation: false — global defaults (editor.tabSize: 2, insertSpaces: false) +set colorcolumn=76 +set noexpandtab +set shiftwidth=2 +set softtabstop=2 +set tabstop=2 + +" colorcolumn draws a full-column tint in Vim (not a VS Code-style 1px line). +" Keep it subtle via the ColorColumn highlight group; reapply after colorscheme changes. +if has('termguicolors') + " set termguicolors +endif + +function! s:ConfigureColorColumn() abort + highlight ColorColumn ctermbg=236 guibg=#2a2a2a cterm=NONE gui=NONE +endfunction + +call s:ConfigureColorColumn() +autocmd ColorScheme * call s:ConfigureColorColumn() + +" files.trimTrailingWhitespace +autocmd BufWritePre * %s/\s\+$//e + +augroup sis_generic + autocmd! + " [bat] + autocmd FileType bat,dosbatch setlocal expandtab tabstop=4 shiftwidth=4 softtabstop=4 colorcolumn=60,76 + + " [c] / [cpp] + autocmd FileType c,cpp setlocal expandtab tabstop=4 shiftwidth=4 softtabstop=4 colorcolumn=60,64,68,72,76 + + " [cmake] + autocmd FileType cmake setlocal noexpandtab tabstop=4 shiftwidth=4 softtabstop=4 + + " [csharp] + autocmd FileType cs,csx setlocal expandtab tabstop=4 shiftwidth=4 softtabstop=4 colorcolumn=76 + + " [go] + autocmd FileType go setlocal noexpandtab tabstop=2 shiftwidth=2 softtabstop=2 colorcolumn=60,76,100 + + " [javascript] / [typescript] + autocmd FileType javascript,javascriptreact,typescript,typescriptreact setlocal expandtab tabstop=2 shiftwidth=2 softtabstop=2 colorcolumn=76 + + " [json] / [markdown] / [ruby] / [yaml] + autocmd FileType json,markdown,ruby,yaml setlocal expandtab tabstop=2 shiftwidth=2 softtabstop=2 + + " [python] + autocmd FileType python setlocal expandtab tabstop=4 shiftwidth=4 softtabstop=4 colorcolumn=50,60,76,120 + + " [rust] + autocmd FileType rust setlocal expandtab tabstop=4 shiftwidth=4 softtabstop=4 colorcolumn=76 + + " [shellscript] + autocmd FileType bash,sh,zsh setlocal expandtab tabstop=2 shiftwidth=2 softtabstop=2 colorcolumn=60,76 + + " [toml] + autocmd FileType toml setlocal noexpandtab tabstop=2 shiftwidth=2 softtabstop=2 + + " [zig] + autocmd FileType zig setlocal expandtab tabstop=4 shiftwidth=4 softtabstop=4 colorcolumn=76 + +augroup END diff --git a/templates/vimrc/go/.gitkeep b/templates/vimrc/go/.gitkeep deleted file mode 100644 index e69de29..0000000 diff --git a/templates/vimrc/go/.vimrc b/templates/vimrc/go/.vimrc new file mode 100644 index 0000000..9385a0c --- /dev/null +++ b/templates/vimrc/go/.vimrc @@ -0,0 +1,54 @@ +" Synesis Go project .vimrc — aligned with .vscode/settings.json (Go) + +set nocompatible +filetype indent plugin on +syntax enable +set autoindent +set backspace=indent,eol,start +set hlsearch +set incsearch +set number + +" files.insertFinalNewline +set eol +set fixeol + +" editor.renderWhitespace: all +set list +set listchars=tab:->,trail:-,extends:>,precedes:<,nbsp:+ + +" editor.detectIndentation: false — global defaults (editor.tabSize: 2, insertSpaces: false) +set colorcolumn=76 +set noexpandtab +set shiftwidth=2 +set softtabstop=2 +set tabstop=2 + +" colorcolumn draws a full-column tint in Vim (not a VS Code-style 1px line). +" Keep it subtle via the ColorColumn highlight group; reapply after colorscheme changes. +if has('termguicolors') + " set termguicolors +endif + +function! s:ConfigureColorColumn() abort + highlight ColorColumn ctermbg=236 guibg=#2a2a2a cterm=NONE gui=NONE +endfunction + +call s:ConfigureColorColumn() +autocmd ColorScheme * call s:ConfigureColorColumn() + +" files.trimTrailingWhitespace +autocmd BufWritePre * %s/\s\+$//e + +augroup sis_go + autocmd! + " [go] — gofmt uses tabs; match .vscode [go] tabSize 2 / insertSpaces false + autocmd FileType go setlocal noexpandtab tabstop=2 shiftwidth=2 softtabstop=2 colorcolumn=60,76,100 + + " [json] / [markdown] / [yaml] + autocmd FileType json,markdown,yaml setlocal expandtab tabstop=2 shiftwidth=2 softtabstop=2 + + " [shellscript] + autocmd FileType bash,sh,zsh setlocal expandtab tabstop=2 shiftwidth=2 softtabstop=2 colorcolumn=60,76 + +augroup END diff --git a/templates/vimrc/javascript/.gitkeep b/templates/vimrc/javascript/.gitkeep deleted file mode 100644 index e69de29..0000000 diff --git a/templates/vimrc/javascript/.vimrc b/templates/vimrc/javascript/.vimrc new file mode 100644 index 0000000..ad825f6 --- /dev/null +++ b/templates/vimrc/javascript/.vimrc @@ -0,0 +1,54 @@ +" Synesis JavaScript project .vimrc — aligned with .vscode/settings.json (JavaScript) + +set nocompatible +filetype indent plugin on +syntax enable +set autoindent +set backspace=indent,eol,start +set hlsearch +set incsearch +set number + +" files.insertFinalNewline +set eol +set fixeol + +" editor.renderWhitespace: all +set list +set listchars=tab:->,trail:-,extends:>,precedes:<,nbsp:+ + +" editor.detectIndentation: false — global defaults match [javascript] (editor.tabSize: 2, insertSpaces: true) +set colorcolumn=76 +set expandtab +set shiftwidth=2 +set softtabstop=2 +set tabstop=2 + +" colorcolumn draws a full-column tint in Vim (not a VS Code-style 1px line). +" Keep it subtle via the ColorColumn highlight group; reapply after colorscheme changes. +if has('termguicolors') + " set termguicolors +endif + +function! s:ConfigureColorColumn() abort + highlight ColorColumn ctermbg=236 guibg=#2a2a2a cterm=NONE gui=NONE +endfunction + +call s:ConfigureColorColumn() +autocmd ColorScheme * call s:ConfigureColorColumn() + +" files.trimTrailingWhitespace +autocmd BufWritePre * %s/\s\+$//e + +augroup sis_javascript + autocmd! + " [javascript] / [typescript] — Prettier / house 2-space + autocmd FileType javascript,javascriptreact,typescript,typescriptreact setlocal expandtab tabstop=2 shiftwidth=2 softtabstop=2 colorcolumn=76 + + " [json] / [markdown] / [yaml] + autocmd FileType json,markdown,yaml setlocal expandtab tabstop=2 shiftwidth=2 softtabstop=2 + + " [shellscript] + autocmd FileType bash,sh,zsh setlocal expandtab tabstop=2 shiftwidth=2 softtabstop=2 colorcolumn=60,76 + +augroup END diff --git a/templates/vimrc/python/.gitkeep b/templates/vimrc/python/.gitkeep deleted file mode 100644 index e69de29..0000000 diff --git a/templates/vimrc/python/.vimrc b/templates/vimrc/python/.vimrc new file mode 100644 index 0000000..602796d --- /dev/null +++ b/templates/vimrc/python/.vimrc @@ -0,0 +1,57 @@ +" Synesis Python project .vimrc — aligned with .vscode/settings.json (Python) + +set nocompatible +filetype indent plugin on +syntax enable +set autoindent +set backspace=indent,eol,start +set hlsearch +set incsearch +set number + +" files.insertFinalNewline +set eol +set fixeol + +" editor.renderWhitespace: all +set list +set listchars=tab:->,trail:-,extends:>,precedes:<,nbsp:+ + +" editor.detectIndentation: false — global defaults match [python] (editor.tabSize: 4, insertSpaces: true) +set colorcolumn=76 +set expandtab +set shiftwidth=4 +set softtabstop=4 +set tabstop=4 + +" colorcolumn draws a full-column tint in Vim (not a VS Code-style 1px line). +" Keep it subtle via the ColorColumn highlight group; reapply after colorscheme changes. +if has('termguicolors') + " set termguicolors +endif + +function! s:ConfigureColorColumn() abort + highlight ColorColumn ctermbg=236 guibg=#2a2a2a cterm=NONE gui=NONE +endfunction + +call s:ConfigureColorColumn() +autocmd ColorScheme * call s:ConfigureColorColumn() + +" files.trimTrailingWhitespace +autocmd BufWritePre * %s/\s\+$//e + +augroup sis_python + autocmd! + " [json] / [markdown] / [yaml] + autocmd FileType json,markdown,yaml setlocal expandtab tabstop=2 shiftwidth=2 softtabstop=2 + + " [python] — match .vscode [python] tabSize 4 / insertSpaces true / rulers 50,60,76,120 + autocmd FileType python setlocal expandtab tabstop=4 shiftwidth=4 softtabstop=4 colorcolumn=50,60,76,120 + + " [shellscript] + autocmd FileType bash,sh,zsh setlocal expandtab tabstop=2 shiftwidth=2 softtabstop=2 colorcolumn=60,76 + + " [toml] + autocmd FileType toml setlocal noexpandtab tabstop=2 shiftwidth=2 softtabstop=2 + +augroup END diff --git a/templates/vimrc/ruby/.gitkeep b/templates/vimrc/ruby/.gitkeep deleted file mode 100644 index e69de29..0000000 diff --git a/templates/vimrc/ruby/.vimrc b/templates/vimrc/ruby/.vimrc new file mode 100644 index 0000000..efb6969 --- /dev/null +++ b/templates/vimrc/ruby/.vimrc @@ -0,0 +1,70 @@ +" Synesis Ruby project .vimrc — aligned with .vscode/settings.json (2-space Ruby) + +set nocompatible +filetype indent plugin on +syntax enable +set autoindent +set backspace=indent,eol,start +set hlsearch +set incsearch +set number + +" files.insertFinalNewline +set eol +set fixeol + +" editor.renderWhitespace: all +set list +set listchars=tab:->,trail:-,extends:>,precedes:<,nbsp:+ + +" editor.detectIndentation: false — global defaults (editor.tabSize: 2, insertSpaces: true) +set colorcolumn=76 +set expandtab +set shiftwidth=2 +set softtabstop=2 +set tabstop=2 + +" colorcolumn draws a full-column tint in Vim (not a VS Code-style 1px line). +" Keep it subtle via the ColorColumn highlight group; reapply after colorscheme changes. +if has('termguicolors') + " set termguicolors +endif + +function! s:ConfigureColorColumn() abort + highlight ColorColumn ctermbg=236 guibg=#2a2a2a cterm=NONE gui=NONE +endfunction + +call s:ConfigureColorColumn() +autocmd ColorScheme * call s:ConfigureColorColumn() + +" files.trimTrailingWhitespace +autocmd BufWritePre * %s/\s\+$//e + +augroup sis_c_cxx + autocmd! + " [bat] + autocmd FileType bat,dosbatch setlocal expandtab tabstop=4 shiftwidth=4 softtabstop=4 colorcolumn=60,76 + + " [c] / [cpp] + autocmd FileType c,cpp setlocal expandtab tabstop=4 shiftwidth=4 softtabstop=4 colorcolumn=60,64,68,72,76 + + " [cmake] + autocmd FileType cmake setlocal noexpandtab tabstop=4 shiftwidth=4 softtabstop=4 + + " [json] / [markdown] / [ruby] / [yaml] + autocmd FileType json,markdown,ruby,yaml setlocal expandtab tabstop=2 shiftwidth=2 softtabstop=2 + + " [python] + autocmd FileType python setlocal expandtab tabstop=4 shiftwidth=4 softtabstop=4 colorcolumn=60,76 + + " [rust] + autocmd FileType rs setlocal expandtab tabstop=4 shiftwidth=4 softtabstop=4 colorcolumn=76 + + " [shellscript] + autocmd FileType bash,sh,zsh setlocal expandtab tabstop=2 shiftwidth=2 softtabstop=2 colorcolumn=60,76 + + " [toml] + autocmd FileType toml setlocal noexpandtab tabstop=2 shiftwidth=2 softtabstop=2 + +augroup END + diff --git a/templates/vimrc/rust/.gitkeep b/templates/vimrc/rust/.gitkeep deleted file mode 100644 index e69de29..0000000 diff --git a/templates/vimrc/rust/.vimrc b/templates/vimrc/rust/.vimrc new file mode 100644 index 0000000..41a4711 --- /dev/null +++ b/templates/vimrc/rust/.vimrc @@ -0,0 +1,70 @@ +" Synesis Rust project .vimrc — aligned with .vscode/settings.json (Rust) + +set nocompatible +filetype indent plugin on +syntax enable +set autoindent +set backspace=indent,eol,start +set hlsearch +set incsearch +set number + +" files.insertFinalNewline +set eol +set fixeol + +" editor.renderWhitespace: all +set list +set listchars=tab:->,trail:-,extends:>,precedes:<,nbsp:+ + +" editor.detectIndentation: false — global defaults (editor.tabSize: 4, insertSpaces: true) +set colorcolumn=76 +set expandtab +set shiftwidth=4 +set softtabstop=4 +set tabstop=4 + +" colorcolumn draws a full-column tint in Vim (not a VS Code-style 1px line). +" Keep it subtle via the ColorColumn highlight group; reapply after colorscheme changes. +if has('termguicolors') + " set termguicolors +endif + +function! s:ConfigureColorColumn() abort + highlight ColorColumn ctermbg=236 guibg=#2a2a2a cterm=NONE gui=NONE +endfunction + +call s:ConfigureColorColumn() +autocmd ColorScheme * call s:ConfigureColorColumn() + +" files.trimTrailingWhitespace +autocmd BufWritePre * %s/\s\+$//e + +augroup sis_rust + autocmd! + " [bat] + autocmd FileType bat,dosbatch setlocal expandtab tabstop=4 shiftwidth=4 softtabstop=4 colorcolumn=60,76 + + " [c] / [cpp] + autocmd FileType c,cpp setlocal expandtab tabstop=4 shiftwidth=4 softtabstop=4 colorcolumn=60,64,68,72,76 + + " [cmake] + autocmd FileType cmake setlocal noexpandtab tabstop=4 shiftwidth=4 softtabstop=4 + + " [json] / [markdown] / [ruby] / [yaml] + autocmd FileType json,markdown,ruby,yaml setlocal expandtab tabstop=2 shiftwidth=2 softtabstop=2 + + " [python] + autocmd FileType python setlocal expandtab tabstop=4 shiftwidth=4 softtabstop=4 colorcolumn=60,76 + + " [rust] + autocmd FileType rust setlocal expandtab tabstop=4 shiftwidth=4 softtabstop=4 colorcolumn=76 + + " [shellscript] + autocmd FileType bash,sh,zsh setlocal expandtab tabstop=2 shiftwidth=2 softtabstop=2 colorcolumn=60,76 + + " [toml] + autocmd FileType toml setlocal noexpandtab tabstop=2 shiftwidth=2 softtabstop=2 + +augroup END + diff --git a/templates/vimrc/zig/.gitkeep b/templates/vimrc/zig/.gitkeep deleted file mode 100644 index e69de29..0000000 diff --git a/templates/vimrc/zig/.vimrc b/templates/vimrc/zig/.vimrc new file mode 100644 index 0000000..3b044aa --- /dev/null +++ b/templates/vimrc/zig/.vimrc @@ -0,0 +1,64 @@ +" Synesis C/C++ & Zig project .vimrc — aligned with .vscode/settings.json + +set nocompatible +filetype indent plugin on +syntax enable +set autoindent +set backspace=indent,eol,start +set hlsearch +set incsearch +set number + +" files.insertFinalNewline +set eol +set fixeol + +" editor.renderWhitespace: all +set list +set listchars=tab:->,trail:-,extends:>,precedes:<,nbsp:+ + +" editor.detectIndentation: false — global defaults (editor.tabSize: 4, insertSpaces: true) +set tabstop=4 +set shiftwidth=4 +set softtabstop=4 +set expandtab +set colorcolumn=76 + +if has('termguicolors') + " set termguicolors +endif + +function! s:ConfigureColorColumn() abort + highlight ColorColumn ctermbg=236 guibg=#2a2a2a cterm=NONE gui=NONE +endfunction + +call s:ConfigureColorColumn() +autocmd ColorScheme * call s:ConfigureColorColumn() + +" files.trimTrailingWhitespace +autocmd BufWritePre * %s/\s\+$//e + +augroup sis_c_cxx_zig + autocmd! + " [bat] + autocmd FileType bat,dosbatch setlocal expandtab tabstop=4 shiftwidth=4 softtabstop=4 colorcolumn=60,76 + + " [c] / [cpp] + autocmd FileType c,cpp setlocal expandtab tabstop=4 shiftwidth=4 softtabstop=4 colorcolumn=60,64,68,72,76 + + " [cmake] + autocmd FileType cmake setlocal noexpandtab tabstop=4 shiftwidth=4 softtabstop=4 + + " [json] / [markdown] / [ruby] / [yaml] + autocmd FileType json,markdown,ruby,yaml setlocal expandtab tabstop=2 shiftwidth=2 softtabstop=2 + + " [shellscript] + autocmd FileType bash,sh,zsh setlocal expandtab tabstop=2 shiftwidth=2 softtabstop=2 colorcolumn=60,76 + + " [toml] + autocmd FileType toml setlocal noexpandtab tabstop=2 shiftwidth=2 softtabstop=2 + + " [zig] + autocmd FileType zig setlocal expandtab tabstop=4 shiftwidth=4 softtabstop=4 colorcolumn=76 + +augroup END diff --git a/templates/vscode/README.md b/templates/vscode/README.md index 12548b7..2f3c74a 100644 --- a/templates/vscode/README.md +++ b/templates/vscode/README.md @@ -1,41 +1,172 @@ # VS Code `settings.json` templates -Drop-in workspace **`.vscode/settings.json`** files, organised by primary language. +**Status:** Phase 2 — canonical copies live here (migrated from **misc-config-scripts** `settings.json/`). -**Status:** Phase 0 — layout only (**`.gitkeep`** placeholders). Until cutover, copy from **misc-config-scripts** `settings.json/` (frozen: no new language templates there). Content will be migrated here in a later phase as **`templates/vscode//settings.json`**. + +Drop-in workspace settings for Synesis / related projects, organised by primary language. ## Table of Contents -- [How to use (once populated)](#how-to-use-once-populated) +- [Formatting conventions in these files](#formatting-conventions-in-these-files) +- [How the contents were chosen](#how-the-contents-were-chosen) +- [How to use](#how-to-use) +- [Language templates](#language-templates) + - [c and cxx](#c-and-cxx) + - [csharp](#csharp) + - [generic](#generic) + - [go](#go) + - [javascript](#javascript) + - [python](#python) + - [ruby](#ruby) + - [rust](#rust) + - [zig](#zig) - [Layout](#layout) +- [Shared house style](#shared-house-style) +- [What is intentionally omitted](#what-is-intentionally-omitted) + + +## Formatting conventions in these files + +These JSONC-style files follow the house layout used across the corpus: + +* **Tabs** for indentation; +* **Trailing commas** on objects and on non-ruler arrays (VS Code allows this); +* **`editor.rulers` arrays closed and compact** on one line, e.g. `"editor.rulers": [ 60, 76 ]`, with **no** trailing comma inside the list; +* **Key order**: language-specific blocks (`[…]`) first, lexicographically among themselves; then all other top-level keys lexicographically; keys within every nested object are lexicographic. + +## How the contents were chosen -## How to use (once populated) +1. **Corpus** — Collected `.vscode/settings.json` (and similar) under `~/dev/synesissoftware`, `~/dev/sistools`, `~/dev/dev-tools`, and `~/dev/sis`, classified by project language (name markers such as `*.Rust` / `*.Go`, plus source-file counts). +2. **Consensus** — For each language, kept settings that appeared consistently (indent, rulers, trim, cmake-on-open, rust-analyzer / gopls / Pylance knobs already in use). +3. **Best practice** — Filled formatter, LSP, and debugger gaps from current official docs (Microsoft VS Code language pages, Shopify Ruby LSP, golang/vscode-go, rust-analyzer, Astral Ruff, zigtools ZLS, C# Dev Kit), not from one-off project hacks. +4. **Synesis constraints** — Preserved house choices that conflict with naive “enable everything” defaults, e.g. `rust-analyzer.cargo.noDefaultFeatures`, clang-format fallback **none** (format only when a `.clang-format` exists), and compact `editor.rulers` lists. + +Project-specific values (linked Cargo projects, feature lists, absolute tool paths, `compile_commands` directories) were **not** copied into the templates. + + +## How to use + +Copy the appropriate file to the target repository as **`.vscode/settings.json`** (create `.vscode/` if needed): ```sh cp templates/vscode//settings.json /path/to/repo/.vscode/settings.json ``` -Prefer the language-specific template that matches the project’s primary language; use **generic** only for multi-language trees. Use **c_cxx** when a mixed native C / C++ settings union is provided. +Prefer the language-specific template that matches the project’s primary language; use **generic** only for multi-language trees or when no single language dominates. Use **c_cxx** when shipping the mixed C / C++ settings copy (identical to **cxx** / **c** today). + + +## Language templates + +### c and cxx + +Folders: **`c/`**, **`c_cxx/`**, **`cxx/`**. + +* **Debugger**: Breakpoints allowed everywhere (headers / macros); concrete debug configs stay in **launch.json** (`cppdbg` / CodeLLDB). +* **Extra**: Large `files.associations` map so extensionless libc++ / MSVC STL headers open as C++ (from the C/C++ corpus). +* **Formatter**: Microsoft C/C++ extension (`ms-vscode.cpptools`) with **clang-format**, `C_Cpp.clang_format_style`: `file`, fallback **`none`** so saves do not rewrite style without a project `.clang-format`. +* **LSP / IntelliSense**: `C_Cpp.intelliSenseEngine`: `default`, squiggles and enhanced colourisation on; defaults **c17** / **c++17**. + +`c` and `cxx` are intentionally almost identical; both ship `[c]` and `[cpp]` blocks because mixed trees are normal. + +### csharp + +Folder: **`c#/`**. + +* **Debugger**: `csharp.debug.justMyCode`, console, step filtering (official `csharp.debug.*` settings). Launch details remain in **launch.json** / `launchSettings.json`. +* **Formatter / LSP**: C# extension / Dev Kit (`ms-dotnettools.csharp`), format on save, organise imports on format (`dotnet.*`). Prefer **dotnet.*** over legacy OmniSharp-only knobs. + +### generic + +**Union** of every language-specific template: + +* all language blocks (`[c]`, `[cpp]`, `[go]`, `[python]`, …); +* all tool namespaces (`C_Cpp.*`, `gopls`, `python.*`, `ruff.*`, `rust-analyzer.*`, `rubyLsp.*`, `zig.*`, …); +* merged `files.exclude` and the C/C++ `files.associations` map. + +Use when a workspace spans multiple languages or the primary language is unclear. Prefer a single-language template when possible to avoid loading irrelevant tool settings. + +### go + +* **Debugger**: `go.delveConfig` for Delve / dlv-dap. +* **Formatter**: `go.formatTool`: **`default`** (gopls — current vscode-go recommendation), with `formatting.gofumpt` enabled. +* **Lint**: `golangci-lint` on workspace save (`--fast`), matching the existing Go corpus. +* **LSP**: `go.useLanguageServer`, gopls semantic tokens / placeholders, vulncheck on imports, common inlay hints. + +### javascript + +* **Debugger**: `debug.javascript.autoAttachFilter`: `smart`. +* **Formatter**: Prettier (`esbenp.prettier-vscode`) on save for JS/TS (and React variants). +* **Lint**: ESLint validate + `source.fixAll.eslint` on save. +* **LSP**: Workspace TypeScript SDK (`typescript.tsdk`), auto-imports, update imports on file move. + +### python + +* **Debugger**: `python.debugpy.debugJustMyCode`: **true**. +* **Formatter / lint**: Ruff extension as default formatter; fix-all and organise-imports on save; `ruff.nativeServer`: **on**. +* **Hygiene**: exclude `__pycache__` / swap files. +* **LSP**: Pylance (`python.languageServer`), standard type checking, workspace diagnostics, selected inlay hints. + +### ruby + +* **Debugger**: use Ruby LSP `launch.json` configs (`type`: `ruby_lsp`); no extra debugger keys required in settings. +* **Formatter / LSP**: Shopify **Ruby LSP** only — the official recommended `[ruby]` block (format on save/type, semantic highlighting) plus `rubyLsp.formatter`: **`auto`** (RuboCop / Syntax Tree from the Gemfile). +* **Not in workspace templates**: `rubyLsp.rubyVersionManager` and executable/Gemfile path overrides (user/machine scope; auto-detect is preferred). + +### rust + +* **Cargo features**: `noDefaultFeatures`: **true** and empty `features` list — matches Synesis libraries with mutually exclusive features (unlike the common `"all"` blog default). +* **Debugger**: CodeLLDB (`rust-analyzer.debug.engine`), `debug.allowBreakpointsEverywhere` (required for rust-analyzer’s simple debug flow). +* **Formatter**: rust-analyzer → rustfmt, format on save. +* **LSP**: `check.command`: **clippy**, `checkOnSave`, `check.allTargets`; proc macros and build scripts on. + +### zig + +* **Debugger**: breakpoints everywhere; use CodeLLDB via **launch.json**. +* **Formatter / LSP**: Official Zig extension + ZLS (`zig.zls.enabled`: **on**); format on save; `editor.suggest.insertMode`: **replace**; optional fix-all / organise-imports code actions (zigtools guidance). ## Layout | Path | Role | -| --- | --- | -| **c/** | C-primary | -| **c#/** | C# / .NET | -| **c_cxx/** | Mixed C / C++ | -| **cxx/** | C++-primary | -| **generic/** | Union / mixed | -| **go/** | Go | -| **javascript/** | JavaScript / TypeScript | -| **python/** | Python | -| **ruby/** | Ruby | -| **rust/** | Rust | -| **zig/** | Zig | +|---|---| +| **c#/settings.json** | C# / .NET projects | +| **c/settings.json** | C-primary projects | +| **c_cxx/settings.json** | Mixed C / C++ (same content as **c** / **cxx**) | +| **cxx/settings.json** | C++-primary projects | +| **generic/settings.json** | Union of all language templates (mixed / unknown) | +| **go/settings.json** | Go projects | +| **javascript/settings.json** | JavaScript / TypeScript projects | +| **python/settings.json** | Python projects | +| **ruby/settings.json** | Ruby projects | +| **rust/settings.json** | Rust projects | +| **zig/settings.json** | Zig projects | + + +## Shared house style + +Every template starts from the same editor hygiene, drawn from the common corpus of Synesis / sistools / related `.vscode/settings.json` files: + +* `cmake.configureOnOpen`: **false** (even in non-CMake languages, for consistency when CMake files appear); +* `editor.detectIndentation`: **false** (explicit indent rules win); +* default `editor.insertSpaces`: **false**, `editor.tabSize`: **2** (language blocks override per language); +* `editor.renderWhitespace`: **all**; +* `editor.rulers`: **[ 76 ]** globally; denser rulers inside language blocks where the corpus used them; +* `files.insertFinalNewline`: **true**, `files.trimTrailingWhitespace`: **true**; +* `git.mergeEditor`: **false**. + +Auxiliary language blocks (e.g. `[json]`, `[markdown]`, `[shellscript]`, `[toml]`) appear wherever those file types commonly sit beside the primary language. + + +## What is intentionally omitted + +* Absolute paths to compilers, `clangd`, or SDKs; +* `compile_commands.json` / build-directory hints (per-repo); +* Editor chrome (themes, font ligatures, exclusive UI prefs); +* `launch.json` / `tasks.json` (debugging *entry* configs belong there); +* `rust-analyzer.linkedProjects` and concrete `cargo.features` lists. diff --git a/templates/vscode/c#/.gitkeep b/templates/vscode/c#/.gitkeep deleted file mode 100644 index e69de29..0000000 diff --git a/templates/vscode/c#/settings.json b/templates/vscode/c#/settings.json new file mode 100644 index 0000000..77f2d9a --- /dev/null +++ b/templates/vscode/c#/settings.json @@ -0,0 +1,44 @@ +{ + "[csharp]": { + "editor.codeActionsOnSave": { + "source.organizeImports": "explicit", + }, + "editor.defaultFormatter": "ms-dotnettools.csharp", + "editor.formatOnSave": true, + "editor.insertSpaces": true, + "editor.rulers": [ 60, 76 ], + "editor.tabSize": 4, + }, + "[json]": { + "editor.insertSpaces": true, + "editor.tabSize": 2, + }, + "[markdown]": { + "editor.insertSpaces": true, + "editor.tabSize": 2, + }, + "[shellscript]": { + "editor.insertSpaces": true, + "editor.rulers": [ 60, 76 ], + "editor.tabSize": 2, + }, + "[toml]": { + "editor.insertSpaces": false, + "editor.tabSize": 2, + }, + "cmake.configureOnOpen": false, + "csharp.debug.console": "internalConsole", + "csharp.debug.enableStepFiltering": true, + "csharp.debug.justMyCode": true, + "dotnet.backgroundAnalysis.analyzerDiagnosticsScope": "openFiles", + "dotnet.completion.showCompletionItemsFromUnimportedNamespaces": true, + "dotnet.formatting.organizeImportsOnFormat": true, + "editor.detectIndentation": false, + "editor.insertSpaces": false, + "editor.renderWhitespace": "all", + "editor.rulers": [ 76 ], + "editor.tabSize": 2, + "files.insertFinalNewline": true, + "files.trimTrailingWhitespace": true, + "git.mergeEditor": false, +} diff --git a/templates/vscode/c/.gitkeep b/templates/vscode/c/.gitkeep deleted file mode 100644 index e69de29..0000000 diff --git a/templates/vscode/c/settings.json b/templates/vscode/c/settings.json new file mode 100644 index 0000000..a20fc3c --- /dev/null +++ b/templates/vscode/c/settings.json @@ -0,0 +1,197 @@ +{ + "[bat]": { + "editor.insertSpaces": true, + "editor.rulers": [ 60, 76 ], + "editor.tabSize": 4, + }, + "[c]": { + "editor.defaultFormatter": "ms-vscode.cpptools", + "editor.formatOnSave": true, + "editor.insertSpaces": true, + "editor.rulers": [ 60, 64, 68, 72, 76 ], + "editor.tabSize": 4, + }, + "[cmake]": { + "editor.insertSpaces": false, + "editor.tabSize": 4, + }, + "[cpp]": { + "editor.defaultFormatter": "ms-vscode.cpptools", + "editor.formatOnSave": true, + "editor.insertSpaces": true, + "editor.rulers": [ 60, 64, 68, 72, 76 ], + "editor.tabSize": 4, + }, + "[json]": { + "editor.insertSpaces": true, + "editor.tabSize": 2, + }, + "[markdown]": { + "editor.insertSpaces": true, + "editor.tabSize": 2, + }, + "[python]": { + "diffEditor.ignoreTrimWhitespace": false, + "editor.insertSpaces": true, + "editor.rulers": [ 51, 60, 61, 76 ], + "editor.tabSize": 4, + }, + "[ruby]": { + "editor.insertSpaces": true, + "editor.tabSize": 2, + }, + "[shellscript]": { + "editor.insertSpaces": true, + "editor.rulers": [ 60, 76 ], + "editor.tabSize": 2, + }, + "[toml]": { + "editor.insertSpaces": false, + "editor.tabSize": 2, + }, + "[yaml]": { + "editor.insertSpaces": true, + "editor.tabSize": 2, + }, + "C_Cpp.autocompleteAddParentheses": true, + "C_Cpp.clang_format_fallbackStyle": "none", + "C_Cpp.clang_format_style": "file", + "C_Cpp.default.cStandard": "c17", + "C_Cpp.default.cppStandard": "c++17", + "C_Cpp.enhancedColorization": "enabled", + "C_Cpp.errorSquiggles": "enabled", + "C_Cpp.formatting": "clangFormat", + "C_Cpp.intelliSenseEngine": "default", + "cmake.configureOnOpen": false, + "debug.allowBreakpointsEverywhere": true, + "editor.detectIndentation": false, + "editor.insertSpaces": false, + "editor.renderWhitespace": "all", + "editor.rulers": [ 76 ], + "editor.tabSize": 2, + "files.associations": { + "__bit_reference": "cpp", + "__bits": "cpp", + "__config": "cpp", + "__debug": "cpp", + "__errc": "cpp", + "__functional_03": "cpp", + "__functional_base": "cpp", + "__hash_table": "cpp", + "__locale": "cpp", + "__memory": "cpp", + "__mutex_base": "cpp", + "__node_handle": "cpp", + "__nullptr": "cpp", + "__split_buffer": "cpp", + "__string": "cpp", + "__threading_support": "cpp", + "__tree": "cpp", + "__tuple": "cpp", + "__verbose_abort": "cpp", + "algorithm": "cpp", + "array": "cpp", + "atomic": "cpp", + "bit": "cpp", + "bitset": "cpp", + "cctype": "cpp", + "charconv": "cpp", + "chrono": "cpp", + "clocale": "cpp", + "cmath": "cpp", + "compare": "cpp", + "complex": "cpp", + "concepts": "cpp", + "console_functions.h": "c", + "corecrt.h": "c", + "crtdefs.h": "c", + "cstdarg": "cpp", + "cstddef": "cpp", + "cstdint": "cpp", + "cstdio": "cpp", + "cstdlib": "cpp", + "cstring": "cpp", + "ctime": "cpp", + "cwchar": "cpp", + "cwctype": "cpp", + "deque": "cpp", + "exception": "cpp", + "execution": "cpp", + "fcntl.h": "c", + "format": "cpp", + "forward_list": "cpp", + "functional": "cpp", + "implicit_link.h": "c", + "initializer_list": "cpp", + "io.h": "c", + "iomanip": "cpp", + "ios": "cpp", + "iosfwd": "cpp", + "iostream": "cpp", + "istream": "cpp", + "iterator": "cpp", + "limits": "cpp", + "list": "cpp", + "locale": "cpp", + "map": "cpp", + "memory": "cpp", + "memory_resource": "cpp", + "mutex": "cpp", + "new": "cpp", + "numbers": "cpp", + "numeric": "cpp", + "optional": "cpp", + "ostream": "cpp", + "print": "cpp", + "queue": "cpp", + "random": "cpp", + "ranges": "cpp", + "ratio": "cpp", + "semaphore": "cpp", + "set": "cpp", + "setenv.h": "c", + "shwild.h": "c", + "span": "cpp", + "sstream": "cpp", + "stack": "cpp", + "stdexcept": "cpp", + "stdio.h": "c", + "stop_token": "cpp", + "streambuf": "cpp", + "string": "cpp", + "string_view": "cpp", + "system_error": "cpp", + "terse-api.h": "c", + "text_encoding": "cpp", + "thread": "cpp", + "tuple": "cpp", + "type_traits": "cpp", + "typeinfo": "cpp", + "uio.h": "c", + "unixem.h": "c", + "unordered_map": "cpp", + "util.h": "c", + "utility": "cpp", + "variant": "cpp", + "vector": "cpp", + "xfacet": "cpp", + "xhash": "cpp", + "xiosbase": "cpp", + "xlocale": "cpp", + "xlocbuf": "cpp", + "xlocinfo": "cpp", + "xlocmes": "cpp", + "xlocmon": "cpp", + "xlocnum": "cpp", + "xloctime": "cpp", + "xmemory": "cpp", + "xstring": "cpp", + "xtests.internal.string.c": "cpp", + "xtr1common": "cpp", + "xtree": "cpp", + "xutility": "cpp", + }, + "files.insertFinalNewline": true, + "files.trimTrailingWhitespace": true, + "git.mergeEditor": false, +} diff --git a/templates/vscode/c_cxx/.gitkeep b/templates/vscode/c_cxx/.gitkeep deleted file mode 100644 index e69de29..0000000 diff --git a/templates/vscode/c_cxx/settings.json b/templates/vscode/c_cxx/settings.json new file mode 100644 index 0000000..a20fc3c --- /dev/null +++ b/templates/vscode/c_cxx/settings.json @@ -0,0 +1,197 @@ +{ + "[bat]": { + "editor.insertSpaces": true, + "editor.rulers": [ 60, 76 ], + "editor.tabSize": 4, + }, + "[c]": { + "editor.defaultFormatter": "ms-vscode.cpptools", + "editor.formatOnSave": true, + "editor.insertSpaces": true, + "editor.rulers": [ 60, 64, 68, 72, 76 ], + "editor.tabSize": 4, + }, + "[cmake]": { + "editor.insertSpaces": false, + "editor.tabSize": 4, + }, + "[cpp]": { + "editor.defaultFormatter": "ms-vscode.cpptools", + "editor.formatOnSave": true, + "editor.insertSpaces": true, + "editor.rulers": [ 60, 64, 68, 72, 76 ], + "editor.tabSize": 4, + }, + "[json]": { + "editor.insertSpaces": true, + "editor.tabSize": 2, + }, + "[markdown]": { + "editor.insertSpaces": true, + "editor.tabSize": 2, + }, + "[python]": { + "diffEditor.ignoreTrimWhitespace": false, + "editor.insertSpaces": true, + "editor.rulers": [ 51, 60, 61, 76 ], + "editor.tabSize": 4, + }, + "[ruby]": { + "editor.insertSpaces": true, + "editor.tabSize": 2, + }, + "[shellscript]": { + "editor.insertSpaces": true, + "editor.rulers": [ 60, 76 ], + "editor.tabSize": 2, + }, + "[toml]": { + "editor.insertSpaces": false, + "editor.tabSize": 2, + }, + "[yaml]": { + "editor.insertSpaces": true, + "editor.tabSize": 2, + }, + "C_Cpp.autocompleteAddParentheses": true, + "C_Cpp.clang_format_fallbackStyle": "none", + "C_Cpp.clang_format_style": "file", + "C_Cpp.default.cStandard": "c17", + "C_Cpp.default.cppStandard": "c++17", + "C_Cpp.enhancedColorization": "enabled", + "C_Cpp.errorSquiggles": "enabled", + "C_Cpp.formatting": "clangFormat", + "C_Cpp.intelliSenseEngine": "default", + "cmake.configureOnOpen": false, + "debug.allowBreakpointsEverywhere": true, + "editor.detectIndentation": false, + "editor.insertSpaces": false, + "editor.renderWhitespace": "all", + "editor.rulers": [ 76 ], + "editor.tabSize": 2, + "files.associations": { + "__bit_reference": "cpp", + "__bits": "cpp", + "__config": "cpp", + "__debug": "cpp", + "__errc": "cpp", + "__functional_03": "cpp", + "__functional_base": "cpp", + "__hash_table": "cpp", + "__locale": "cpp", + "__memory": "cpp", + "__mutex_base": "cpp", + "__node_handle": "cpp", + "__nullptr": "cpp", + "__split_buffer": "cpp", + "__string": "cpp", + "__threading_support": "cpp", + "__tree": "cpp", + "__tuple": "cpp", + "__verbose_abort": "cpp", + "algorithm": "cpp", + "array": "cpp", + "atomic": "cpp", + "bit": "cpp", + "bitset": "cpp", + "cctype": "cpp", + "charconv": "cpp", + "chrono": "cpp", + "clocale": "cpp", + "cmath": "cpp", + "compare": "cpp", + "complex": "cpp", + "concepts": "cpp", + "console_functions.h": "c", + "corecrt.h": "c", + "crtdefs.h": "c", + "cstdarg": "cpp", + "cstddef": "cpp", + "cstdint": "cpp", + "cstdio": "cpp", + "cstdlib": "cpp", + "cstring": "cpp", + "ctime": "cpp", + "cwchar": "cpp", + "cwctype": "cpp", + "deque": "cpp", + "exception": "cpp", + "execution": "cpp", + "fcntl.h": "c", + "format": "cpp", + "forward_list": "cpp", + "functional": "cpp", + "implicit_link.h": "c", + "initializer_list": "cpp", + "io.h": "c", + "iomanip": "cpp", + "ios": "cpp", + "iosfwd": "cpp", + "iostream": "cpp", + "istream": "cpp", + "iterator": "cpp", + "limits": "cpp", + "list": "cpp", + "locale": "cpp", + "map": "cpp", + "memory": "cpp", + "memory_resource": "cpp", + "mutex": "cpp", + "new": "cpp", + "numbers": "cpp", + "numeric": "cpp", + "optional": "cpp", + "ostream": "cpp", + "print": "cpp", + "queue": "cpp", + "random": "cpp", + "ranges": "cpp", + "ratio": "cpp", + "semaphore": "cpp", + "set": "cpp", + "setenv.h": "c", + "shwild.h": "c", + "span": "cpp", + "sstream": "cpp", + "stack": "cpp", + "stdexcept": "cpp", + "stdio.h": "c", + "stop_token": "cpp", + "streambuf": "cpp", + "string": "cpp", + "string_view": "cpp", + "system_error": "cpp", + "terse-api.h": "c", + "text_encoding": "cpp", + "thread": "cpp", + "tuple": "cpp", + "type_traits": "cpp", + "typeinfo": "cpp", + "uio.h": "c", + "unixem.h": "c", + "unordered_map": "cpp", + "util.h": "c", + "utility": "cpp", + "variant": "cpp", + "vector": "cpp", + "xfacet": "cpp", + "xhash": "cpp", + "xiosbase": "cpp", + "xlocale": "cpp", + "xlocbuf": "cpp", + "xlocinfo": "cpp", + "xlocmes": "cpp", + "xlocmon": "cpp", + "xlocnum": "cpp", + "xloctime": "cpp", + "xmemory": "cpp", + "xstring": "cpp", + "xtests.internal.string.c": "cpp", + "xtr1common": "cpp", + "xtree": "cpp", + "xutility": "cpp", + }, + "files.insertFinalNewline": true, + "files.trimTrailingWhitespace": true, + "git.mergeEditor": false, +} diff --git a/templates/vscode/cxx/.gitkeep b/templates/vscode/cxx/.gitkeep deleted file mode 100644 index e69de29..0000000 diff --git a/templates/vscode/cxx/settings.json b/templates/vscode/cxx/settings.json new file mode 100644 index 0000000..a20fc3c --- /dev/null +++ b/templates/vscode/cxx/settings.json @@ -0,0 +1,197 @@ +{ + "[bat]": { + "editor.insertSpaces": true, + "editor.rulers": [ 60, 76 ], + "editor.tabSize": 4, + }, + "[c]": { + "editor.defaultFormatter": "ms-vscode.cpptools", + "editor.formatOnSave": true, + "editor.insertSpaces": true, + "editor.rulers": [ 60, 64, 68, 72, 76 ], + "editor.tabSize": 4, + }, + "[cmake]": { + "editor.insertSpaces": false, + "editor.tabSize": 4, + }, + "[cpp]": { + "editor.defaultFormatter": "ms-vscode.cpptools", + "editor.formatOnSave": true, + "editor.insertSpaces": true, + "editor.rulers": [ 60, 64, 68, 72, 76 ], + "editor.tabSize": 4, + }, + "[json]": { + "editor.insertSpaces": true, + "editor.tabSize": 2, + }, + "[markdown]": { + "editor.insertSpaces": true, + "editor.tabSize": 2, + }, + "[python]": { + "diffEditor.ignoreTrimWhitespace": false, + "editor.insertSpaces": true, + "editor.rulers": [ 51, 60, 61, 76 ], + "editor.tabSize": 4, + }, + "[ruby]": { + "editor.insertSpaces": true, + "editor.tabSize": 2, + }, + "[shellscript]": { + "editor.insertSpaces": true, + "editor.rulers": [ 60, 76 ], + "editor.tabSize": 2, + }, + "[toml]": { + "editor.insertSpaces": false, + "editor.tabSize": 2, + }, + "[yaml]": { + "editor.insertSpaces": true, + "editor.tabSize": 2, + }, + "C_Cpp.autocompleteAddParentheses": true, + "C_Cpp.clang_format_fallbackStyle": "none", + "C_Cpp.clang_format_style": "file", + "C_Cpp.default.cStandard": "c17", + "C_Cpp.default.cppStandard": "c++17", + "C_Cpp.enhancedColorization": "enabled", + "C_Cpp.errorSquiggles": "enabled", + "C_Cpp.formatting": "clangFormat", + "C_Cpp.intelliSenseEngine": "default", + "cmake.configureOnOpen": false, + "debug.allowBreakpointsEverywhere": true, + "editor.detectIndentation": false, + "editor.insertSpaces": false, + "editor.renderWhitespace": "all", + "editor.rulers": [ 76 ], + "editor.tabSize": 2, + "files.associations": { + "__bit_reference": "cpp", + "__bits": "cpp", + "__config": "cpp", + "__debug": "cpp", + "__errc": "cpp", + "__functional_03": "cpp", + "__functional_base": "cpp", + "__hash_table": "cpp", + "__locale": "cpp", + "__memory": "cpp", + "__mutex_base": "cpp", + "__node_handle": "cpp", + "__nullptr": "cpp", + "__split_buffer": "cpp", + "__string": "cpp", + "__threading_support": "cpp", + "__tree": "cpp", + "__tuple": "cpp", + "__verbose_abort": "cpp", + "algorithm": "cpp", + "array": "cpp", + "atomic": "cpp", + "bit": "cpp", + "bitset": "cpp", + "cctype": "cpp", + "charconv": "cpp", + "chrono": "cpp", + "clocale": "cpp", + "cmath": "cpp", + "compare": "cpp", + "complex": "cpp", + "concepts": "cpp", + "console_functions.h": "c", + "corecrt.h": "c", + "crtdefs.h": "c", + "cstdarg": "cpp", + "cstddef": "cpp", + "cstdint": "cpp", + "cstdio": "cpp", + "cstdlib": "cpp", + "cstring": "cpp", + "ctime": "cpp", + "cwchar": "cpp", + "cwctype": "cpp", + "deque": "cpp", + "exception": "cpp", + "execution": "cpp", + "fcntl.h": "c", + "format": "cpp", + "forward_list": "cpp", + "functional": "cpp", + "implicit_link.h": "c", + "initializer_list": "cpp", + "io.h": "c", + "iomanip": "cpp", + "ios": "cpp", + "iosfwd": "cpp", + "iostream": "cpp", + "istream": "cpp", + "iterator": "cpp", + "limits": "cpp", + "list": "cpp", + "locale": "cpp", + "map": "cpp", + "memory": "cpp", + "memory_resource": "cpp", + "mutex": "cpp", + "new": "cpp", + "numbers": "cpp", + "numeric": "cpp", + "optional": "cpp", + "ostream": "cpp", + "print": "cpp", + "queue": "cpp", + "random": "cpp", + "ranges": "cpp", + "ratio": "cpp", + "semaphore": "cpp", + "set": "cpp", + "setenv.h": "c", + "shwild.h": "c", + "span": "cpp", + "sstream": "cpp", + "stack": "cpp", + "stdexcept": "cpp", + "stdio.h": "c", + "stop_token": "cpp", + "streambuf": "cpp", + "string": "cpp", + "string_view": "cpp", + "system_error": "cpp", + "terse-api.h": "c", + "text_encoding": "cpp", + "thread": "cpp", + "tuple": "cpp", + "type_traits": "cpp", + "typeinfo": "cpp", + "uio.h": "c", + "unixem.h": "c", + "unordered_map": "cpp", + "util.h": "c", + "utility": "cpp", + "variant": "cpp", + "vector": "cpp", + "xfacet": "cpp", + "xhash": "cpp", + "xiosbase": "cpp", + "xlocale": "cpp", + "xlocbuf": "cpp", + "xlocinfo": "cpp", + "xlocmes": "cpp", + "xlocmon": "cpp", + "xlocnum": "cpp", + "xloctime": "cpp", + "xmemory": "cpp", + "xstring": "cpp", + "xtests.internal.string.c": "cpp", + "xtr1common": "cpp", + "xtree": "cpp", + "xutility": "cpp", + }, + "files.insertFinalNewline": true, + "files.trimTrailingWhitespace": true, + "git.mergeEditor": false, +} diff --git a/templates/vscode/generic/.gitkeep b/templates/vscode/generic/.gitkeep deleted file mode 100644 index e69de29..0000000 diff --git a/templates/vscode/generic/settings.json b/templates/vscode/generic/settings.json new file mode 100644 index 0000000..d693b94 --- /dev/null +++ b/templates/vscode/generic/settings.json @@ -0,0 +1,363 @@ +{ + "[bat]": { + "editor.insertSpaces": true, + "editor.rulers": [ 60, 76 ], + "editor.tabSize": 4, + }, + "[c]": { + "editor.defaultFormatter": "ms-vscode.cpptools", + "editor.formatOnSave": true, + "editor.insertSpaces": true, + "editor.rulers": [ 60, 64, 68, 72, 76 ], + "editor.tabSize": 4, + }, + "[cmake]": { + "editor.insertSpaces": false, + "editor.tabSize": 4, + }, + "[cpp]": { + "editor.defaultFormatter": "ms-vscode.cpptools", + "editor.formatOnSave": true, + "editor.insertSpaces": true, + "editor.rulers": [ 60, 64, 68, 72, 76 ], + "editor.tabSize": 4, + }, + "[csharp]": { + "editor.codeActionsOnSave": { + "source.organizeImports": "explicit", + }, + "editor.defaultFormatter": "ms-dotnettools.csharp", + "editor.formatOnSave": true, + "editor.insertSpaces": true, + "editor.rulers": [ 60, 76 ], + "editor.tabSize": 4, + }, + "[go]": { + "editor.codeActionsOnSave": { + "source.organizeImports": "explicit", + }, + "editor.defaultFormatter": "golang.go", + "editor.formatOnSave": true, + "editor.insertSpaces": false, + "editor.tabSize": 2, + }, + "[javascript]": { + "editor.codeActionsOnSave": { + "source.fixAll.eslint": "explicit", + }, + "editor.defaultFormatter": "esbenp.prettier-vscode", + "editor.formatOnSave": true, + "editor.insertSpaces": true, + "editor.tabSize": 2, + }, + "[javascriptreact]": { + "editor.codeActionsOnSave": { + "source.fixAll.eslint": "explicit", + }, + "editor.defaultFormatter": "esbenp.prettier-vscode", + "editor.formatOnSave": true, + "editor.insertSpaces": true, + "editor.tabSize": 2, + }, + "[json]": { + "editor.insertSpaces": true, + "editor.tabSize": 2, + }, + "[markdown]": { + "editor.insertSpaces": true, + "editor.tabSize": 2, + }, + "[python]": { + "diffEditor.ignoreTrimWhitespace": false, + "editor.codeActionsOnSave": { + "source.fixAll": "explicit", + "source.organizeImports": "explicit", + }, + "editor.defaultFormatter": "charliermarsh.ruff", + "editor.formatOnSave": true, + "editor.insertSpaces": true, + "editor.rulers": [ 60, 76 ], + "editor.tabSize": 4, + }, + "[ruby]": { + "editor.defaultFormatter": "Shopify.ruby-lsp", + "editor.formatOnSave": true, + "editor.formatOnType": true, + "editor.insertSpaces": true, + "editor.rulers": [ 60, 76 ], + "editor.semanticHighlighting.enabled": true, + "editor.tabSize": 2, + }, + "[rust]": { + "editor.defaultFormatter": "rust-lang.rust-analyzer", + "editor.formatOnSave": true, + "editor.insertSpaces": true, + "editor.rulers": [ 60, 76 ], + "editor.tabSize": 4, + }, + "[shellscript]": { + "editor.insertSpaces": true, + "editor.rulers": [ 60, 76 ], + "editor.tabSize": 2, + }, + "[toml]": { + "editor.insertSpaces": false, + "editor.tabSize": 2, + }, + "[typescript]": { + "editor.codeActionsOnSave": { + "source.fixAll.eslint": "explicit", + }, + "editor.defaultFormatter": "esbenp.prettier-vscode", + "editor.formatOnSave": true, + "editor.insertSpaces": true, + "editor.tabSize": 2, + }, + "[typescriptreact]": { + "editor.codeActionsOnSave": { + "source.fixAll.eslint": "explicit", + }, + "editor.defaultFormatter": "esbenp.prettier-vscode", + "editor.formatOnSave": true, + "editor.insertSpaces": true, + "editor.tabSize": 2, + }, + "[yaml]": { + "editor.insertSpaces": true, + "editor.tabSize": 2, + }, + "[zig]": { + "editor.codeActionsOnSave": { + "source.fixAll": "explicit", + "source.organizeImports": "explicit", + }, + "editor.defaultFormatter": "ziglang.vscode-zig", + "editor.formatOnSave": true, + "editor.insertSpaces": true, + "editor.suggest.insertMode": "replace", + "editor.tabSize": 4, + }, + "C_Cpp.autocompleteAddParentheses": true, + "C_Cpp.clang_format_fallbackStyle": "none", + "C_Cpp.clang_format_style": "file", + "C_Cpp.default.cStandard": "c17", + "C_Cpp.default.cppStandard": "c++17", + "C_Cpp.enhancedColorization": "enabled", + "C_Cpp.errorSquiggles": "enabled", + "C_Cpp.formatting": "clangFormat", + "C_Cpp.intelliSenseEngine": "default", + "cmake.configureOnOpen": false, + "csharp.debug.console": "internalConsole", + "csharp.debug.enableStepFiltering": true, + "csharp.debug.justMyCode": true, + "debug.allowBreakpointsEverywhere": true, + "debug.javascript.autoAttachFilter": "smart", + "debug.javascript.breakOnConditionalError": true, + "dotnet.backgroundAnalysis.analyzerDiagnosticsScope": "openFiles", + "dotnet.completion.showCompletionItemsFromUnimportedNamespaces": true, + "dotnet.formatting.organizeImportsOnFormat": true, + "editor.detectIndentation": false, + "editor.insertSpaces": false, + "editor.renderWhitespace": "all", + "editor.rulers": [ 76 ], + "editor.tabSize": 2, + "eslint.enable": true, + "eslint.validate": [ + "javascript", + "javascriptreact", + "typescript", + "typescriptreact", + ], + "files.associations": { + "__bit_reference": "cpp", + "__bits": "cpp", + "__config": "cpp", + "__debug": "cpp", + "__errc": "cpp", + "__functional_03": "cpp", + "__functional_base": "cpp", + "__hash_table": "cpp", + "__locale": "cpp", + "__memory": "cpp", + "__mutex_base": "cpp", + "__node_handle": "cpp", + "__nullptr": "cpp", + "__split_buffer": "cpp", + "__string": "cpp", + "__threading_support": "cpp", + "__tree": "cpp", + "__tuple": "cpp", + "__verbose_abort": "cpp", + "algorithm": "cpp", + "array": "cpp", + "atomic": "cpp", + "bit": "cpp", + "bitset": "cpp", + "cctype": "cpp", + "charconv": "cpp", + "chrono": "cpp", + "clocale": "cpp", + "cmath": "cpp", + "compare": "cpp", + "complex": "cpp", + "concepts": "cpp", + "console_functions.h": "c", + "corecrt.h": "c", + "crtdefs.h": "c", + "cstdarg": "cpp", + "cstddef": "cpp", + "cstdint": "cpp", + "cstdio": "cpp", + "cstdlib": "cpp", + "cstring": "cpp", + "ctime": "cpp", + "cwchar": "cpp", + "cwctype": "cpp", + "deque": "cpp", + "exception": "cpp", + "execution": "cpp", + "fcntl.h": "c", + "format": "cpp", + "forward_list": "cpp", + "functional": "cpp", + "implicit_link.h": "c", + "initializer_list": "cpp", + "io.h": "c", + "iomanip": "cpp", + "ios": "cpp", + "iosfwd": "cpp", + "iostream": "cpp", + "istream": "cpp", + "iterator": "cpp", + "limits": "cpp", + "list": "cpp", + "locale": "cpp", + "map": "cpp", + "memory": "cpp", + "memory_resource": "cpp", + "mutex": "cpp", + "new": "cpp", + "numbers": "cpp", + "numeric": "cpp", + "optional": "cpp", + "ostream": "cpp", + "print": "cpp", + "queue": "cpp", + "random": "cpp", + "ranges": "cpp", + "ratio": "cpp", + "semaphore": "cpp", + "set": "cpp", + "setenv.h": "c", + "shwild.h": "c", + "span": "cpp", + "sstream": "cpp", + "stack": "cpp", + "stdexcept": "cpp", + "stdio.h": "c", + "stop_token": "cpp", + "streambuf": "cpp", + "string": "cpp", + "string_view": "cpp", + "system_error": "cpp", + "terse-api.h": "c", + "text_encoding": "cpp", + "thread": "cpp", + "tuple": "cpp", + "type_traits": "cpp", + "typeinfo": "cpp", + "uio.h": "c", + "unixem.h": "c", + "unordered_map": "cpp", + "util.h": "c", + "utility": "cpp", + "variant": "cpp", + "vector": "cpp", + "xfacet": "cpp", + "xhash": "cpp", + "xiosbase": "cpp", + "xlocale": "cpp", + "xlocbuf": "cpp", + "xlocinfo": "cpp", + "xlocmes": "cpp", + "xlocmon": "cpp", + "xlocnum": "cpp", + "xloctime": "cpp", + "xmemory": "cpp", + "xstring": "cpp", + "xtests.internal.string.c": "cpp", + "xtr1common": "cpp", + "xtree": "cpp", + "xutility": "cpp", + }, + "files.exclude": { + "***.swp": true, + "**/__pycache__": true, + "**/node_modules": true, + }, + "files.insertFinalNewline": true, + "files.trimTrailingWhitespace": true, + "git.mergeEditor": false, + "go.delveConfig": { + "apiVersion": 2, + "dlvLoadConfig": { + "followPointers": true, + "maxArrayValues": 64, + "maxStringLen": 64, + "maxStructFields": -1, + "maxVariableRecurse": 1, + }, + "showGlobalVariables": false, + }, + "go.diagnostic.vulncheck": "Imports", + "go.formatTool": "default", + "go.inlayHints.constantValues": true, + "go.inlayHints.functionTypeParameters": true, + "go.inlayHints.parameterNames": true, + "go.inlayHints.rangeVariableTypes": true, + "go.lintFlags": [ + "--fast", + ], + "go.lintOnSave": "workspace", + "go.lintTool": "golangci-lint", + "go.toolsManagement.autoUpdate": true, + "go.useLanguageServer": true, + "gopls": { + "formatting.gofumpt": true, + "ui.completion.usePlaceholders": true, + "ui.semanticTokens": true, + }, + "javascript.preferences.importModuleSpecifier": "relative", + "javascript.suggest.autoImports": true, + "javascript.updateImportsOnFileMove.enabled": "always", + "python.analysis.autoImportCompletions": true, + "python.analysis.completeFunctionParens": true, + "python.analysis.diagnosticMode": "workspace", + "python.analysis.inlayHints.functionReturnTypes": true, + "python.analysis.inlayHints.variableTypes": true, + "python.analysis.typeCheckingMode": "standard", + "python.debugpy.debugJustMyCode": true, + "python.languageServer": "Pylance", + "rubyLsp.formatter": "auto", + "ruff.enable": true, + "ruff.fixAll": true, + "ruff.nativeServer": "on", + "ruff.organizeImports": true, + "rust-analyzer.cargo.buildScripts.enable": true, + "rust-analyzer.cargo.features": [], + "rust-analyzer.cargo.noDefaultFeatures": true, + "rust-analyzer.check.allTargets": true, + "rust-analyzer.check.command": "clippy", + "rust-analyzer.checkOnSave": true, + "rust-analyzer.completion.autoimport.enable": false, + "rust-analyzer.debug.engine": "vadimcn.vscode-lldb", + "rust-analyzer.debug.openDebugPane": true, + "rust-analyzer.procMacro.enable": true, + "rust-analyzer.showUnlinkedFileNotification": false, + "typescript.enablePromptUseWorkspaceTsdk": true, + "typescript.preferences.importModuleSpecifier": "relative", + "typescript.suggest.autoImports": true, + "typescript.tsdk": "node_modules/typescript/lib", + "typescript.updateImportsOnFileMove.enabled": "always", + "zig.zls.enabled": "on", +} diff --git a/templates/vscode/go/.gitkeep b/templates/vscode/go/.gitkeep deleted file mode 100644 index e69de29..0000000 diff --git a/templates/vscode/go/settings.json b/templates/vscode/go/settings.json new file mode 100644 index 0000000..43778ba --- /dev/null +++ b/templates/vscode/go/settings.json @@ -0,0 +1,70 @@ +{ + "[go]": { + "editor.codeActionsOnSave": { + "source.organizeImports": "explicit", + }, + "editor.defaultFormatter": "golang.go", + "editor.formatOnSave": true, + "editor.insertSpaces": false, + "editor.tabSize": 2, + }, + "[json]": { + "editor.insertSpaces": true, + "editor.tabSize": 2, + }, + "[markdown]": { + "editor.insertSpaces": true, + "editor.tabSize": 2, + }, + "[ruby]": { + "editor.insertSpaces": true, + "editor.tabSize": 2, + }, + "[shellscript]": { + "editor.insertSpaces": true, + "editor.rulers": [ 60, 76 ], + "editor.tabSize": 2, + }, + "[toml]": { + "editor.insertSpaces": false, + "editor.tabSize": 2, + }, + "cmake.configureOnOpen": false, + "editor.detectIndentation": false, + "editor.insertSpaces": false, + "editor.renderWhitespace": "all", + "editor.rulers": [ 76 ], + "editor.tabSize": 2, + "files.insertFinalNewline": true, + "files.trimTrailingWhitespace": true, + "git.mergeEditor": false, + "go.delveConfig": { + "apiVersion": 2, + "dlvLoadConfig": { + "followPointers": true, + "maxArrayValues": 64, + "maxStringLen": 64, + "maxStructFields": -1, + "maxVariableRecurse": 1, + }, + "showGlobalVariables": false, + }, + "go.diagnostic.vulncheck": "Imports", + "go.formatTool": "default", + "go.inlayHints.constantValues": true, + "go.inlayHints.functionTypeParameters": true, + "go.inlayHints.parameterNames": true, + "go.inlayHints.rangeVariableTypes": true, + "go.lintFlags": [ + "--fast", + ], + "go.lintOnSave": "workspace", + "go.lintTool": "golangci-lint", + "go.toolsManagement.autoUpdate": true, + "go.useLanguageServer": true, + "gopls": { + "formatting.gofumpt": true, + "ui.completion.usePlaceholders": true, + "ui.semanticTokens": true, + }, +} diff --git a/templates/vscode/javascript/.gitkeep b/templates/vscode/javascript/.gitkeep deleted file mode 100644 index e69de29..0000000 diff --git a/templates/vscode/javascript/settings.json b/templates/vscode/javascript/settings.json new file mode 100644 index 0000000..7e36fa9 --- /dev/null +++ b/templates/vscode/javascript/settings.json @@ -0,0 +1,80 @@ +{ + "[javascript]": { + "editor.codeActionsOnSave": { + "source.fixAll.eslint": "explicit", + }, + "editor.defaultFormatter": "esbenp.prettier-vscode", + "editor.formatOnSave": true, + "editor.insertSpaces": true, + "editor.tabSize": 2, + }, + "[javascriptreact]": { + "editor.codeActionsOnSave": { + "source.fixAll.eslint": "explicit", + }, + "editor.defaultFormatter": "esbenp.prettier-vscode", + "editor.formatOnSave": true, + "editor.insertSpaces": true, + "editor.tabSize": 2, + }, + "[json]": { + "editor.insertSpaces": true, + "editor.tabSize": 2, + }, + "[markdown]": { + "editor.insertSpaces": true, + "editor.tabSize": 2, + }, + "[shellscript]": { + "editor.insertSpaces": true, + "editor.rulers": [ 60, 76 ], + "editor.tabSize": 2, + }, + "[typescript]": { + "editor.codeActionsOnSave": { + "source.fixAll.eslint": "explicit", + }, + "editor.defaultFormatter": "esbenp.prettier-vscode", + "editor.formatOnSave": true, + "editor.insertSpaces": true, + "editor.tabSize": 2, + }, + "[typescriptreact]": { + "editor.codeActionsOnSave": { + "source.fixAll.eslint": "explicit", + }, + "editor.defaultFormatter": "esbenp.prettier-vscode", + "editor.formatOnSave": true, + "editor.insertSpaces": true, + "editor.tabSize": 2, + }, + "cmake.configureOnOpen": false, + "debug.javascript.autoAttachFilter": "smart", + "debug.javascript.breakOnConditionalError": true, + "editor.detectIndentation": false, + "editor.insertSpaces": false, + "editor.renderWhitespace": "all", + "editor.rulers": [ 76 ], + "editor.tabSize": 2, + "eslint.enable": true, + "eslint.validate": [ + "javascript", + "javascriptreact", + "typescript", + "typescriptreact", + ], + "files.exclude": { + "**/node_modules": true, + }, + "files.insertFinalNewline": true, + "files.trimTrailingWhitespace": true, + "git.mergeEditor": false, + "javascript.preferences.importModuleSpecifier": "relative", + "javascript.suggest.autoImports": true, + "javascript.updateImportsOnFileMove.enabled": "always", + "typescript.enablePromptUseWorkspaceTsdk": true, + "typescript.preferences.importModuleSpecifier": "relative", + "typescript.suggest.autoImports": true, + "typescript.tsdk": "node_modules/typescript/lib", + "typescript.updateImportsOnFileMove.enabled": "always", +} diff --git a/templates/vscode/python/.gitkeep b/templates/vscode/python/.gitkeep deleted file mode 100644 index e69de29..0000000 diff --git a/templates/vscode/python/settings.json b/templates/vscode/python/settings.json new file mode 100644 index 0000000..10a0b1d --- /dev/null +++ b/templates/vscode/python/settings.json @@ -0,0 +1,60 @@ +{ + "[json]": { + "editor.insertSpaces": true, + "editor.tabSize": 2, + }, + "[markdown]": { + "editor.insertSpaces": true, + "editor.tabSize": 2, + }, + "[python]": { + "diffEditor.ignoreTrimWhitespace": false, + "editor.codeActionsOnSave": { + "source.fixAll": "explicit", + "source.organizeImports": "explicit", + }, + "editor.defaultFormatter": "charliermarsh.ruff", + "editor.formatOnSave": true, + "editor.insertSpaces": true, + "editor.rulers": [ 60, 76 ], + "editor.tabSize": 4, + }, + "[shellscript]": { + "editor.insertSpaces": true, + "editor.rulers": [ 60, 76 ], + "editor.tabSize": 2, + }, + "[toml]": { + "editor.insertSpaces": false, + "editor.tabSize": 2, + }, + "[yaml]": { + "editor.insertSpaces": true, + "editor.tabSize": 2, + }, + "cmake.configureOnOpen": false, + "editor.detectIndentation": false, + "editor.insertSpaces": false, + "editor.renderWhitespace": "all", + "editor.rulers": [ 76 ], + "editor.tabSize": 2, + "files.exclude": { + "***.swp": true, + "**/__pycache__": true, + }, + "files.insertFinalNewline": true, + "files.trimTrailingWhitespace": true, + "git.mergeEditor": false, + "python.analysis.autoImportCompletions": true, + "python.analysis.completeFunctionParens": true, + "python.analysis.diagnosticMode": "workspace", + "python.analysis.inlayHints.functionReturnTypes": true, + "python.analysis.inlayHints.variableTypes": true, + "python.analysis.typeCheckingMode": "standard", + "python.debugpy.debugJustMyCode": true, + "python.languageServer": "Pylance", + "ruff.enable": true, + "ruff.fixAll": true, + "ruff.nativeServer": "on", + "ruff.organizeImports": true, +} diff --git a/templates/vscode/ruby/.gitkeep b/templates/vscode/ruby/.gitkeep deleted file mode 100644 index e69de29..0000000 diff --git a/templates/vscode/ruby/settings.json b/templates/vscode/ruby/settings.json new file mode 100644 index 0000000..19efccd --- /dev/null +++ b/templates/vscode/ruby/settings.json @@ -0,0 +1,43 @@ +{ + "[json]": { + "editor.insertSpaces": true, + "editor.tabSize": 2, + }, + "[markdown]": { + "editor.insertSpaces": true, + "editor.tabSize": 2, + }, + "[python]": { + "editor.insertSpaces": true, + "editor.rulers": [ 60, 76 ], + "editor.tabSize": 4, + }, + "[ruby]": { + "editor.defaultFormatter": "Shopify.ruby-lsp", + "editor.formatOnSave": true, + "editor.formatOnType": true, + "editor.insertSpaces": true, + "editor.rulers": [ 60, 76 ], + "editor.semanticHighlighting.enabled": true, + "editor.tabSize": 2, + }, + "[shellscript]": { + "editor.insertSpaces": true, + "editor.rulers": [ 60, 76 ], + "editor.tabSize": 2, + }, + "[toml]": { + "editor.insertSpaces": false, + "editor.tabSize": 2, + }, + "cmake.configureOnOpen": false, + "editor.detectIndentation": false, + "editor.insertSpaces": false, + "editor.renderWhitespace": "all", + "editor.rulers": [ 76 ], + "editor.tabSize": 2, + "files.insertFinalNewline": true, + "files.trimTrailingWhitespace": true, + "git.mergeEditor": false, + "rubyLsp.formatter": "auto", +} diff --git a/templates/vscode/rust/.gitkeep b/templates/vscode/rust/.gitkeep deleted file mode 100644 index e69de29..0000000 diff --git a/templates/vscode/rust/settings.json b/templates/vscode/rust/settings.json new file mode 100644 index 0000000..2cfe147 --- /dev/null +++ b/templates/vscode/rust/settings.json @@ -0,0 +1,57 @@ +{ + "[json]": { + "editor.insertSpaces": true, + "editor.tabSize": 2, + }, + "[markdown]": { + "editor.insertSpaces": true, + "editor.tabSize": 2, + }, + "[python]": { + "editor.insertSpaces": true, + "editor.rulers": [ 60, 76 ], + "editor.tabSize": 4, + }, + "[ruby]": { + "editor.insertSpaces": true, + "editor.rulers": [ 60, 76 ], + "editor.tabSize": 2, + }, + "[rust]": { + "editor.defaultFormatter": "rust-lang.rust-analyzer", + "editor.formatOnSave": true, + "editor.insertSpaces": true, + "editor.rulers": [ 60, 76 ], + "editor.tabSize": 4, + }, + "[shellscript]": { + "editor.insertSpaces": true, + "editor.rulers": [ 60, 76 ], + "editor.tabSize": 2, + }, + "[toml]": { + "editor.insertSpaces": false, + "editor.tabSize": 2, + }, + "cmake.configureOnOpen": false, + "debug.allowBreakpointsEverywhere": true, + "editor.detectIndentation": false, + "editor.insertSpaces": false, + "editor.renderWhitespace": "all", + "editor.rulers": [ 76 ], + "editor.tabSize": 2, + "files.insertFinalNewline": true, + "files.trimTrailingWhitespace": true, + "git.mergeEditor": false, + "rust-analyzer.cargo.buildScripts.enable": true, + "rust-analyzer.cargo.features": [], + "rust-analyzer.cargo.noDefaultFeatures": true, + "rust-analyzer.check.allTargets": true, + "rust-analyzer.check.command": "clippy", + "rust-analyzer.checkOnSave": true, + "rust-analyzer.completion.autoimport.enable": false, + "rust-analyzer.debug.engine": "vadimcn.vscode-lldb", + "rust-analyzer.debug.openDebugPane": true, + "rust-analyzer.procMacro.enable": true, + "rust-analyzer.showUnlinkedFileNotification": false, +} diff --git a/templates/vscode/zig/.gitkeep b/templates/vscode/zig/.gitkeep deleted file mode 100644 index e69de29..0000000 diff --git a/templates/vscode/zig/settings.json b/templates/vscode/zig/settings.json new file mode 100644 index 0000000..50947dc --- /dev/null +++ b/templates/vscode/zig/settings.json @@ -0,0 +1,36 @@ +{ + "[json]": { + "editor.insertSpaces": true, + "editor.tabSize": 2, + }, + "[markdown]": { + "editor.insertSpaces": true, + "editor.tabSize": 2, + }, + "[toml]": { + "editor.insertSpaces": false, + "editor.tabSize": 2, + }, + "[zig]": { + "editor.codeActionsOnSave": { + "source.fixAll": "explicit", + "source.organizeImports": "explicit", + }, + "editor.defaultFormatter": "ziglang.vscode-zig", + "editor.formatOnSave": true, + "editor.insertSpaces": true, + "editor.suggest.insertMode": "replace", + "editor.tabSize": 4, + }, + "cmake.configureOnOpen": false, + "debug.allowBreakpointsEverywhere": true, + "editor.detectIndentation": false, + "editor.insertSpaces": false, + "editor.renderWhitespace": "all", + "editor.rulers": [ 76 ], + "editor.tabSize": 2, + "files.insertFinalNewline": true, + "files.trimTrailingWhitespace": true, + "git.mergeEditor": false, + "zig.zls.enabled": "on", +} From 1be369c66c3fff70157d79e6135625afd3f2f75e Mon Sep 17 00:00:00 2001 From: Matt Wilson Date: Tue, 15 Sep 2026 09:06:03 +1000 Subject: [PATCH 4/7] docs(misc-dev-scripts): note m-c-s 0.9.0 cutover for project drop-ins Record that templates/ is the sole canonical home after misc-config-scripts removed its legacy catalogs. --- README.md | 26 ++++++++++++-------------- TODO.md | 3 ++- templates/README.md | 6 +++--- templates/gitattributes/README.md | 2 +- templates/vscode/README.md | 2 +- 5 files changed, 19 insertions(+), 20 deletions(-) diff --git a/README.md b/README.md index 8d47a90..5dc53f2 100644 --- a/README.md +++ b/README.md @@ -13,7 +13,7 @@ Miscellaneous Development Scripts ## Table of Contents - [Introduction](#introduction) -- [Ownership and migration (Phase 0)](#ownership-and-migration-phase-0) +- [Ownership and migration](#ownership-and-migration) - [Catalogue layout](#catalogue-layout) - [Shell Scripts](#shell-scripts) - [run\_all\_unit\_tests.sh](#run_all_unit_testssh) @@ -28,12 +28,12 @@ Miscellaneous Development Scripts Today the shipped helpers are principally **run_all_unit_tests.sh** variants for **JavaScript**, **Python**, and **Ruby**, with further languages and template families planned. When updating a consumer, cite this repository’s **VERSION** in that project’s **CHANGES.md**. -Sibling project: [**misc-config-scripts**](https://github.com/synesissoftware/misc-config-scripts) (**`.commonrc`** and **`.gitconfig`** only after cutover). +Sibling project: [**misc-config-scripts**](https://github.com/synesissoftware/misc-config-scripts) (**`.commonrc`** and **`.gitconfig`** only). -## Ownership and migration (Phase 0) +## Ownership and migration -**Status: Phase 2 complete — `templates/` is populated and is the canonical home for project drop-ins.** Legacy copies may still exist in **misc-config-scripts** until that repo’s Phase 3. +**Status: Phase 3 complete — this repository’s `templates/` is the sole canonical home for project drop-ins.** **misc-config-scripts** **0.9.0+** ships **`.commonrc`** / **`.gitconfig`** only. Distinguish **self** boilerplate (this repository’s own root editor/Git files) from **templates** (copied into other projects). @@ -41,9 +41,7 @@ Distinguish **self** boilerplate (this repository’s own root editor/Git files) | --- | --- | --- | | **Self** **`.editorconfig`**, **`.gitattributes`**, **`.gitignore`**, **`.vimrc`**, **`.vscode/settings.json`** | ✅ | ✅ | | **Templates:** **`.gitconfig`**, **`.commonrc`** | ✅ only | ❌ | -| **Templates:** language-specific **`run_all_unit_tests.sh`**, **`.editorconfig`**, **`.gitattributes`**, **`.gitignore`**, **`.vimrc`**, **`.vscode/settings.json`** | ❌ (legacy frozen) | ✅ only | - -Until **misc-config-scripts** Phase 3 removes its legacy trees, prefer **this** repository’s **`templates/`** for new copies of VS Code settings and **`.gitattributes`**. Do **not** add new language templates under **misc-config-scripts**. +| **Templates:** language-specific **`run_all_unit_tests.sh`**, **`.editorconfig`**, **`.gitattributes`**, **`.gitignore`**, **`.vimrc`**, **`.vscode/settings.json`** | ❌ | ✅ only | ## Catalogue layout @@ -87,18 +85,18 @@ Use `--help` on any variant for the authoritative flag list. See [**templates/README.md**](./templates/README.md). Families: -* [**editorconfig**](./templates/editorconfig/README.md); -* [**gitattributes**](./templates/gitattributes/README.md); -* [**gitignore**](./templates/gitignore/README.md); -* [**vimrc**](./templates/vimrc/README.md); -* [**vscode**](./templates/vscode/README.md); +* [**.editorconfig**](./templates/editorconfig/README.md); +* [**.gitattributes**](./templates/gitattributes/README.md); +* [**.gitignore**](./templates/gitignore/README.md); +* [**.vimrc**](./templates/vimrc/README.md); +* [**.vscode/**](./templates/vscode/README.md); -**Phase 2:** all families populated for every language key — ready to copy. +**Phase 2:** all families populated for every language key — ready to copy. **misc-config-scripts** **0.9.0+** no longer ships legacy catalogs. ## Related projects -A peer project that provides **`.commonrc`** and **`.gitconfig`** (and, until cutover, legacy project settings / gitattributes catalogs) is [**misc-config-scripts**](https://github.com/synesissoftware/misc-config-scripts). +A peer project that provides **`.commonrc`** and **`.gitconfig`** is [**misc-config-scripts**](https://github.com/synesissoftware/misc-config-scripts) (**0.9.0+**). Resources from this project are used in the following projects (case-insensitive lexicographic order): diff --git a/TODO.md b/TODO.md index 26c0909..803537b 100644 --- a/TODO.md +++ b/TODO.md @@ -91,7 +91,8 @@ * [x] ~~~Phase 0: declare ownership; scaffold **templates/** catalogue layout + READMEs~~~ - ✅; * [x] ~~~Phase 1: complete **self** boilerplate (**`.editorconfig`**; retarget root **`.vimrc`** as self for this Bash catalog, not C/C++ consumer gold; seed **templates/vimrc/c_cxx/.vimrc**)~~~ - ✅; * [x] ~~~Phase 2: populate **templates/** from freelibs exemplars and migrate **misc-config-scripts** `settings.json/` + `gitattributes/` content~~~ - ✅; -* [ ] Phase 4: refresh this repo’s self **`.vscode/settings.json`** (and related self files) from **templates/vscode/generic/** (or shell-appropriate) once populated; +* [x] ~~~Phase 3 companion: **misc-config-scripts** **0.9.0** removed legacy catalogs; this repo remains sole project-drop-in home~~~ - ✅; +* [ ] Phase 4: refresh this repo’s self **`.vscode/settings.json`** (and related self files) from **templates/vscode/generic/** (or shell-appropriate); * [ ] Later: hoist **build_dist.sh** / **build_dist_uv.sh** (Python), **build_gem.sh** (Ruby), **rustfmt.toml** / **scripts/fmt** (Rust), Go **build.sh** / runners, and further common helpers under **shell-scripts/** or **templates/** as appropriate; * [ ] Optional: sample bootstrap notes for copy-vs-sync adoption; * [ ] Distribution / drift control: `SCRIPT_VERSION` header matching **VERSION**; document consumer CHANGES citation convention; optional sync helper; optional `testdata/` CI fixtures; diff --git a/templates/README.md b/templates/README.md index 9170bde..49c6786 100644 --- a/templates/README.md +++ b/templates/README.md @@ -19,14 +19,14 @@ This tree is the **canonical catalogue** for project-local config files that con ## Status -**Phase 2 (populated):** all five families × eleven language keys hold copyable templates. Prefer these paths over the legacy catalogs still present (frozen) in **misc-config-scripts** `settings.json/` and `gitattributes/` until that repo’s Phase 3 removal. +**Phase 3 complete:** all five families × eleven language keys hold copyable templates. This tree is the sole canonical home (legacy **misc-config-scripts** `settings.json/` and `gitattributes/` catalogs removed in that repo’s **0.9.0**). ## Self boilerplate vs templates | Kind | Where | Purpose | | --- | --- | --- | -| **Self** | Repository root (e.g. this project’s own **`.vimrc`**, **`.gitignore`**) | Configures *this* repository | +| **Self** | Repository root (e.g. this project's own **`.vimrc`**, **`.gitignore`**) | Configures *this* repository | | **Template** | Under **`templates///`** | Copied into *other* projects | Do not confuse root self files with the catalogue under **`templates/`**. @@ -91,7 +91,7 @@ When updating a consumer, cite this repository’s **VERSION** in that project ## Related * [**shell-scripts/run_all_unit_tests/README.md**](../shell-scripts/run_all_unit_tests/README.md) — test-runner helpers; -* Sibling [**misc-config-scripts**](https://github.com/synesissoftware/misc-config-scripts) — **`.gitconfig`** and **`.commonrc`**; legacy project catalogs frozen until Phase 3. +* Sibling [**misc-config-scripts**](https://github.com/synesissoftware/misc-config-scripts) — **`.gitconfig`** and **`.commonrc`** only (**0.9.0+**); diff --git a/templates/gitattributes/README.md b/templates/gitattributes/README.md index 8bfd9db..adddd55 100644 --- a/templates/gitattributes/README.md +++ b/templates/gitattributes/README.md @@ -1,7 +1,7 @@ # `.gitattributes` templates -**Status:** Phase 2 — canonical copies live here (migrated from **misc-config-scripts** `gitattributes/`). +**Status:** Canonical copies live here (migrated from former **misc-config-scripts** `gitattributes/` catalogs; that tree was removed in **misc-config-scripts** **0.9.0**). Drop-in root **`.gitattributes`** files for GitHub-hosted repositories, organised by primary language. diff --git a/templates/vscode/README.md b/templates/vscode/README.md index 2f3c74a..550c997 100644 --- a/templates/vscode/README.md +++ b/templates/vscode/README.md @@ -1,7 +1,7 @@ # VS Code `settings.json` templates -**Status:** Phase 2 — canonical copies live here (migrated from **misc-config-scripts** `settings.json/`). +**Status:** Canonical copies live here (migrated from former **misc-config-scripts** `settings.json/` catalogs; that tree was removed in **misc-config-scripts** **0.9.0**). Drop-in workspace settings for Synesis / related projects, organised by primary language. From 2d92885506a699f82e0765b1453d69ea2acdb75b Mon Sep 17 00:00:00 2001 From: Matt Wilson Date: Tue, 15 Sep 2026 09:51:33 +1000 Subject: [PATCH 5/7] chore(misc-dev-scripts): Phase 4 align self with templates gold Refresh root `.gitignore` from `templates/gitignore/generic/`; normalise self `.gitattributes` to shell/docs catalog form; confirm `.vscode` matches generic gold; keep shell/docs `.editorconfig` / `.vimrc`; fold notes into 0.6.0 CHANGES/NEWS/TODO/README. --- .gitattributes | 10 ++++------ .gitignore | 19 ++++++++++++++++++- CHANGES.md | 7 ++++++- NEWS.md | 2 +- README.md | 2 +- TODO.md | 2 +- 6 files changed, 31 insertions(+), 11 deletions(-) diff --git a/.gitattributes b/.gitattributes index 93a7579..4496d68 100644 --- a/.gitattributes +++ b/.gitattributes @@ -1,8 +1,7 @@ -# .gitattributes — misc-dev-scripts (Bash helper catalog) +# .gitattributes — misc-dev-scripts (shell / docs catalog self) # -# Aligned with misc-config-scripts shell / shared baseline patterns. -# Prefer a language-specific template from that sibling when copying into -# a primary-language library. +# Self boilerplate for this repository. Project drop-in templates live under +# templates/gitattributes/. # Default: detect text, normalize to LF in the repository * text=auto @@ -29,10 +28,9 @@ TODO text VERSION text # --- Config --- -**/.gitattributes -linguist-vendored linguist-language=Git-Attributes linguist-detectable -**/settings.json linguist-language=JSON-with-Comments linguist-detectable *.json text *.yaml text *.yml text .gitattributes -linguist-vendored linguist-language=Git-Attributes linguist-detectable settings.json linguist-language=JSON-with-Comments linguist-detectable +**/settings.json linguist-language=JSON-with-Comments linguist-detectable diff --git a/.gitignore b/.gitignore index 6a8c6ab..34e32d3 100644 --- a/.gitignore +++ b/.gitignore @@ -1,11 +1,24 @@ +# Synesis Information Systems .gitignore for mixed-language / generic trees + # directories (by name) +/.idea/ +/.venv/ +/.vs/ +/build/ +/coverage/ +/dist/ +/node_modules/ /scratch/ +/target/ +/tmp/ # directories (by pattern) +**/__pycache__/ + # files (by name) @@ -15,7 +28,11 @@ # files (by pattern) *~ +*.dll +*.dylib +*.exe +*.o +*.so *.sw[ponm] *.tmp *.zip - diff --git a/CHANGES.md b/CHANGES.md index 36fe598..9677684 100644 --- a/CHANGES.md +++ b/CHANGES.md @@ -25,8 +25,13 @@ * **templates/editorconfig/** — freelibs **python** / **ruby** plus synthesized house rules for other languages; * **templates/gitignore/** — lean Synesis-header consensus per language; * **templates/vimrc/**: lexicographically ordered language sections and combined `[label]` / `FileType` lists (revisibility); +* Phase 4: align self boilerplate with **templates/** gold: + * confirmed **`.vscode/settings.json`** byte-identical to **templates/vscode/generic/settings.json**; + * refreshed **`.gitignore`** from **templates/gitignore/generic/**; + * normalised self **`.gitattributes`** to shell / docs catalog form (templates remain under **templates/gitattributes/**); + * retained shell / docs **`.editorconfig`** and **`.vimrc`** (not replaced by language-generic consumer templates); * Updated **templates/** READMEs (status, copy commands, layout); -* Updated **README.md** (Phase 2 canonical; prefer **templates/** over legacy m-c-s catalogs); +* Updated **README.md** (Phase 2–3 canonical; prefer **templates/** over legacy m-c-s catalogs); ## 0.5.3 - 15th September 2026 diff --git a/NEWS.md b/NEWS.md index 47ff0c3..aae1d4b 100644 --- a/NEWS.md +++ b/NEWS.md @@ -3,7 +3,7 @@ | Date | News Item | Details | | -------------------- | --------- | ------- | -| 15th September 2026 | [**misc-dev-scripts** 0.6.0](https://github.com/synesissoftware/misc-dev-scripts/releases/tag/0.6.0) released | Phase 2: populate `templates/` catalogue | +| 15th September 2026 | [**misc-dev-scripts** 0.6.0](https://github.com/synesissoftware/misc-dev-scripts/releases/tag/0.6.0) released | Phase 2–4: templates catalogue + self align | | 15th September 2026 | [**misc-dev-scripts** 0.5.3](https://github.com/synesissoftware/misc-dev-scripts/releases/tag/0.5.3) released | Phase 1 self boilerplate; c_cxx vimrc seed | | 15th September 2026 | [**misc-dev-scripts** 0.5.2](https://github.com/synesissoftware/misc-dev-scripts/releases/tag/0.5.2) released | Phase 0 ownership; `templates/` scaffold | | 14th September 2026 | [**misc-dev-scripts** 0.5.1](https://github.com/synesissoftware/misc-dev-scripts/releases/tag/0.5.1) released | Python `.sis` help + prefer project `.venv` | diff --git a/README.md b/README.md index 5dc53f2..c36be55 100644 --- a/README.md +++ b/README.md @@ -33,7 +33,7 @@ Sibling project: [**misc-config-scripts**](https://github.com/synesissoftware/mi ## Ownership and migration -**Status: Phase 3 complete — this repository’s `templates/` is the sole canonical home for project drop-ins.** **misc-config-scripts** **0.9.0+** ships **`.commonrc`** / **`.gitconfig`** only. +**Status: Phase 4 complete — self boilerplate aligned with `templates/` gold where applicable.** **misc-config-scripts** **0.9.0+** ships **`.commonrc`** / **`.gitconfig`** only. Distinguish **self** boilerplate (this repository’s own root editor/Git files) from **templates** (copied into other projects). diff --git a/TODO.md b/TODO.md index 803537b..59e7712 100644 --- a/TODO.md +++ b/TODO.md @@ -92,7 +92,7 @@ * [x] ~~~Phase 1: complete **self** boilerplate (**`.editorconfig`**; retarget root **`.vimrc`** as self for this Bash catalog, not C/C++ consumer gold; seed **templates/vimrc/c_cxx/.vimrc**)~~~ - ✅; * [x] ~~~Phase 2: populate **templates/** from freelibs exemplars and migrate **misc-config-scripts** `settings.json/` + `gitattributes/` content~~~ - ✅; * [x] ~~~Phase 3 companion: **misc-config-scripts** **0.9.0** removed legacy catalogs; this repo remains sole project-drop-in home~~~ - ✅; -* [ ] Phase 4: refresh this repo’s self **`.vscode/settings.json`** (and related self files) from **templates/vscode/generic/** (or shell-appropriate); +* [x] ~~~Phase 4: align self **`.vscode/settings.json`**, **`.gitignore`**, and **`.gitattributes`** with **templates/** gold (keep shell/docs **`.editorconfig`** / **`.vimrc`**)~~~ - ✅; * [ ] Later: hoist **build_dist.sh** / **build_dist_uv.sh** (Python), **build_gem.sh** (Ruby), **rustfmt.toml** / **scripts/fmt** (Rust), Go **build.sh** / runners, and further common helpers under **shell-scripts/** or **templates/** as appropriate; * [ ] Optional: sample bootstrap notes for copy-vs-sync adoption; * [ ] Distribution / drift control: `SCRIPT_VERSION` header matching **VERSION**; document consumer CHANGES citation convention; optional sync helper; optional `testdata/` CI fixtures; From cb98ac1dd58c32d95e3a0ad5555fa4c20ddee82d Mon Sep 17 00:00:00 2001 From: Matt Wilson Date: Fri, 18 Sep 2026 07:35:43 +1000 Subject: [PATCH 6/7] .vscode/settings.json --- .vscode/settings.json | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.vscode/settings.json b/.vscode/settings.json index d693b94..7b522c7 100644 --- a/.vscode/settings.json +++ b/.vscode/settings.json @@ -246,6 +246,8 @@ "random": "cpp", "ranges": "cpp", "ratio": "cpp", + "rc.h": "c", + "result_codes_.h": "c", "semaphore": "cpp", "set": "cpp", "setenv.h": "c", From 1bea4bd01f876f6c988ad897b2a985a0a23d75f8 Mon Sep 17 00:00:00 2001 From: Matt Wilson Date: Fri, 18 Sep 2026 07:40:11 +1000 Subject: [PATCH 7/7] chore(.gitignore, .vscode/settings.json): standardisation in lieu of C/C++ standardisation effort --- CHANGES.md | 6 + templates/README.md | 2 +- templates/gitignore/README.md | 5 +- templates/gitignore/c/.gitignore | 172 ++++++++++++++++++++++- templates/gitignore/c_cxx/.gitignore | 186 +++++++++++++++++++++++-- templates/gitignore/cxx/.gitignore | 172 ++++++++++++++++++++++- templates/vscode/c/settings.json | 22 +++ templates/vscode/c_cxx/settings.json | 27 +++- templates/vscode/cxx/settings.json | 22 +++ templates/vscode/generic/settings.json | 2 + 10 files changed, 599 insertions(+), 17 deletions(-) diff --git a/CHANGES.md b/CHANGES.md index 9677684..eae131b 100644 --- a/CHANGES.md +++ b/CHANGES.md @@ -3,6 +3,7 @@ ## Table of Contents +- [Unreleased](#unreleased) - [0.6.0 - 15th September 2026](#060---15th-september-2026) - [0.5.3 - 15th September 2026](#053---15th-september-2026) - [0.5.2 - 15th September 2026](#052---15th-september-2026) @@ -16,6 +17,11 @@ - [0.1.1 - 11th August 2026](#011---11th-august-2026) +## Unreleased + +* Expanded **templates/gitignore/{c,cxx,c_cxx}/** from the lean 0.6.0 consensus to the historical Synesis C/C++ ignore union (gold section layout; MSVC, logs, IDE, artefact dirs; omits `.vscode/` and owning-library `/include/` `/src/` trees); + + ## 0.6.0 - 15th September 2026 * Phase 2: populate **templates/** as the canonical project drop-in catalogue: diff --git a/templates/README.md b/templates/README.md index 49c6786..a9b91ae 100644 --- a/templates/README.md +++ b/templates/README.md @@ -38,7 +38,7 @@ Do not confuse root self files with the catalogue under **`templates/`**. | --- | --- | --- | | **editorconfig** | **misc-dev-scripts** `templates/editorconfig/` | Seeded from freelibs exemplars + house indent rules | | **gitattributes** | **misc-dev-scripts** `templates/gitattributes/` | Migrated from **misc-config-scripts** `gitattributes/` | -| **gitignore** | **misc-dev-scripts** `templates/gitignore/` | Lean Synesis-header consensus per language | +| **gitignore** | **misc-dev-scripts** `templates/gitignore/` | C/C++ keys: historical Synesis union; other langs: lean consensus | | **vimrc** | **misc-dev-scripts** `templates/vimrc/` | Freelibs language gold (+ synthesized JS / generic) | | **vscode** (`settings.json`) | **misc-dev-scripts** `templates/vscode/` | Migrated from **misc-config-scripts** `settings.json/` | | **run_all_unit_tests.sh** | **misc-dev-scripts** `shell-scripts/run_all_unit_tests/` | Already canonical | diff --git a/templates/gitignore/README.md b/templates/gitignore/README.md index 8fea902..d58debd 100644 --- a/templates/gitignore/README.md +++ b/templates/gitignore/README.md @@ -3,7 +3,10 @@ Drop-in root **`.gitignore`** files, organised by primary language. -**Status:** Phase 2 — populated (lean Synesis-header consensus from freelibs exemplars; not a dump of every historical project ignore). +**Status:** Phase 2 — populated. **c** / **cxx** / **c_cxx** are the historical +Synesis C/C++ ignore union (gold section layout: directories by name, directories +by pattern, files by name, files by pattern). Other language keys remain lean +house consensus. Projects may still add local paths after copying. ## Table of Contents diff --git a/templates/gitignore/c/.gitignore b/templates/gitignore/c/.gitignore index 32b2561..ee5f414 100644 --- a/templates/gitignore/c/.gitignore +++ b/templates/gitignore/c/.gitignore @@ -3,44 +3,212 @@ # directories (by name) +.svn/ +/.git-old/ /.idea/ /.vs/ /_analyses/ -/_build/ /_build-ci/ +/_build/ +/_internal/ /bin/ +/docs/ +/dox/ +/ideas/ +/include/xcontract/ +/include/xcover/ +/included/ /ipch/ /lib/ +/releases/ /scratch/ +/src/xcontract/ +/src/xcover/ /target/ +/temp/ +Debug Multithreaded DLL/ +Debug Multithreaded Dll/ +Debug Multithreaded pseudoUNIX/ +Debug Multithreaded pseudoUnix/ +Debug Multithreaded/ +Debug/ +DebugDLL/ +DebugDLLUNIX/ +DebugDll/ +DebugMTDLL/ +DebugMTDll/ +DebugMTUnix/ +DebugMt/ +DebugNox/ +DebugUNIX/ +DebugUnix/ +Release Multithreaded DLL/ +Release Multithreaded Dll/ +Release Multithreaded pseudoUNIX/ +Release Multithreaded pseudoUnix/ +Release Multithreaded/ +Release/ +ReleaseDLL/ +ReleaseDLLUNIX/ +ReleaseDll/ +ReleaseMTDLL/ +ReleaseMTDll/ +ReleaseMTUnix/ +ReleaseMt/ +ReleaseNox/ +ReleaseUnix/ +UDebug/ +UDebugMt/ +URelease/ +UReleaseMt/ +Unicode Debug Multithreaded DLL/ +Unicode Debug Multithreaded Dll/ +Unicode Debug Multithreaded/ +Unicode Debug/ +Unicode Release Multithreaded DLL/ +Unicode Release Multithreaded Dll/ +Unicode Release Multithreaded/ +Unicode Release/ +Win32/ bin/ +ideas/ ipch/ lib/ +perf_test/ +projects/util/vc10-generated/ +scripts/internal/ +x64/ # directories (by pattern) +/include-*/ + # files (by name) .DS_Store +.classpath +.env.development.local +.env.local +.env.production.local +.env.test.local +.ruby-version +.ruby-version-exclusions +.svnignore +.svnignore-at-root +.update_deps +/--include +/--src +/-include +/-src +/__pycache__ +/dox +/examples/bin +/examples/c/bin +/examples/c/lib +/examples/cpp/bin +/examples/cpp/lib +/examples/lib +/node_modules +build/CMakeCache.txt +build/makefile.tmpl +build/makefile.tools.xml +build/shwild.tmplgen +include/fastformat/internal/dos2unix.has.been.performed +include/pantheios/internal/dos2unix.has.been.performed +include/stlsoft/dos2unix.has.been.performed +include/stlsoft/internal/dos2unix.has.been.performed +list_changes.cmd +logging-bailout.txt +prepare.cmd +sh.exe.stackdump +test/testpatterns.orj +test/tests-plan.txt +tidydir.cmd +update_deps.cmd # files (by pattern) -*~ +*.*~ +*.???_obj +*.VC.db +*.VC.opendb *.a +*.app +*.aps +*.b64 +*.bak +*.chm +*.class +*.csproj*user +*.d +*.diff *.dll +*.dsp *.dylib *.exe *.gch +*.gem +*.idb +*.ilk +*.iobj +*.ipch +*.ipdb +*.la +*.lai *.lib +*.lo +*.log +*.ncb *.o *.obj +*.opensdf +*.opt +*.org *.out *.pch *.pdb +*.pyc +*.rar +*.res +*.sbr +*.scc +*.sdf +*.slo *.so +*.suo *.sw[ponm] +*.swp +*.test +*.tlog *.tmp +*.unsuccessfulbuild +*.vc71.sln +*.vc8.sln +*.vc9.sln +*.vcproj*.user +*.vcproj*user +*.vcxproj*.user +*.vcxproj*user +*.xcuserstate *.zip +*~ +/build/*.zip +/build/ar* +/build/bc5* +/build/como* +/build/cw* +/build/gcc3* +/build/gcc4* +/build/icl* +/build/vc5* +RCa0* +RCb0* +build/*.tmpl +build/*.tmplgen +build/*.tools.xml +npm-debug.log* +yarn-debug.log* +yarn-error.log* diff --git a/templates/gitignore/c_cxx/.gitignore b/templates/gitignore/c_cxx/.gitignore index 8b69d23..226c160 100644 --- a/templates/gitignore/c_cxx/.gitignore +++ b/templates/gitignore/c_cxx/.gitignore @@ -3,44 +3,212 @@ # directories (by name) -/.idea/ -/.vs/ +bin/ +ideas/ +ipch/ +lib/ +scripts/internal/ +Win32/ +x64/ + +.idea/ +.svn/ +.vs/ + +__pycache__/ + /_analyses/ -/_build/ /_build-ci/ -/bin/ -/ipch/ -/lib/ +/_build/ +/_internal/ + +/docs/ +/dox/ +/ideas/ +/include/xcontract/ +/include/xcover/ +/included/ +/node_modules/ +/releases/ /scratch/ +/src/xcontract/ +/src/xcover/ /target/ -bin/ -ipch/ -lib/ +/temp/ + +/examples/bin/ +/examples/c/bin/ +/examples/c/lib/ +/examples/cpp/bin/ +/examples/cpp/lib/ +/examples/lib/ + +Debug Multithreaded Dll/ +Debug Multithreaded DLL/ +Debug Multithreaded pseudoUnix/ +Debug Multithreaded pseudoUNIX/ +Debug Multithreaded/ +Debug/ +DebugDll/ +DebugDLL/ +DebugDLLUNIX/ +DebugMt/ +DebugMTDll/ +DebugMTDLL/ +DebugMTUnix/ +DebugNox/ +DebugUnix/ +DebugUNIX/ +Release Multithreaded Dll/ +Release Multithreaded DLL/ +Release Multithreaded pseudoUnix/ +Release Multithreaded pseudoUNIX/ +Release Multithreaded/ +Release/ +ReleaseDll/ +ReleaseDLL/ +ReleaseDLLUNIX/ +ReleaseMt/ +ReleaseMTDll/ +ReleaseMTDLL/ +ReleaseMTUnix/ +ReleaseNox/ +ReleaseUnix/ +UDebug/ +UDebugMt/ +Unicode Debug Multithreaded Dll/ +Unicode Debug Multithreaded DLL/ +Unicode Debug Multithreaded/ +Unicode Debug/ +Unicode Release Multithreaded Dll/ +Unicode Release Multithreaded DLL/ +Unicode Release Multithreaded/ +Unicode Release/ +URelease/ +UReleaseMt/ # directories (by pattern) +/include-*/ + # files (by name) .DS_Store +.classpath +.env.development.local +.env.local +.env.production.local +.env.test.local +.ruby-version +.svnignore +.svnignore-at-root +.update_deps + +build/CMakeCache.txt +build/makefile.tmpl +build/makefile.tools.xml +build/shwild.tmplgen +include/pantheios/internal/dos2unix.has.been.performed +include/stlsoft/dos2unix.has.been.performed +include/stlsoft/internal/dos2unix.has.been.performed +list_changes.cmd +logging-bailout.txt +prepare.cmd +sh.exe.stackdump +test/testpatterns.orj +test/tests-plan.txt +tidydir.cmd +update_deps.cmd + # files (by pattern) *~ +*.*~ +*.???_obj *.a +*.app +*.aps +*.b64 +*.bak +*.chm +*.class +*.csproj*user +*.d +*.diff *.dll +*.dsp *.dylib *.exe *.gch +*.gem +*.idb +*.ilk +*.iobj +*.ipch +*.ipdb +*.la +*.lai *.lib +*.lo +*.log +*.ncb *.o *.obj +*.opensdf +*.opt +*.org *.out *.pch *.pdb +*.pyc +*.rar +*.res +*.sbr +*.scc +*.sdf +*.slo *.so +*.suo *.sw[ponm] +*.swp +*.test +*.tlog *.tmp +*.unsuccessfulbuild +*.VC.db +*.VC.opendb +*.xcuserstate *.zip + +/build/*.tmpl +/build/*.tmplgen +/build/*.tools.xml +/build/*.zip +/build/ar* +/build/bc5* +/build/como* +/build/cw* +/build/gcc3* +/build/gcc4* +/build/icl* +/build/vc5* + +RCa0* +RCb0* + +npm-debug.log* +yarn-debug.log* +yarn-error.log* + +*.vc71.sln +*.vc8.sln +*.vc9.sln +*.vcproj*.user +*.vcproj*user +*.vcxproj*.user +*.vcxproj*user + diff --git a/templates/gitignore/cxx/.gitignore b/templates/gitignore/cxx/.gitignore index 3ee81f9..c6aa4b2 100644 --- a/templates/gitignore/cxx/.gitignore +++ b/templates/gitignore/cxx/.gitignore @@ -3,44 +3,212 @@ # directories (by name) +.svn/ +/.git-old/ /.idea/ /.vs/ /_analyses/ -/_build/ /_build-ci/ +/_build/ +/_internal/ /bin/ +/docs/ +/dox/ +/ideas/ +/include/xcontract/ +/include/xcover/ +/included/ /ipch/ /lib/ +/releases/ /scratch/ +/src/xcontract/ +/src/xcover/ /target/ +/temp/ +Debug Multithreaded DLL/ +Debug Multithreaded Dll/ +Debug Multithreaded pseudoUNIX/ +Debug Multithreaded pseudoUnix/ +Debug Multithreaded/ +Debug/ +DebugDLL/ +DebugDLLUNIX/ +DebugDll/ +DebugMTDLL/ +DebugMTDll/ +DebugMTUnix/ +DebugMt/ +DebugNox/ +DebugUNIX/ +DebugUnix/ +Release Multithreaded DLL/ +Release Multithreaded Dll/ +Release Multithreaded pseudoUNIX/ +Release Multithreaded pseudoUnix/ +Release Multithreaded/ +Release/ +ReleaseDLL/ +ReleaseDLLUNIX/ +ReleaseDll/ +ReleaseMTDLL/ +ReleaseMTDll/ +ReleaseMTUnix/ +ReleaseMt/ +ReleaseNox/ +ReleaseUnix/ +UDebug/ +UDebugMt/ +URelease/ +UReleaseMt/ +Unicode Debug Multithreaded DLL/ +Unicode Debug Multithreaded Dll/ +Unicode Debug Multithreaded/ +Unicode Debug/ +Unicode Release Multithreaded DLL/ +Unicode Release Multithreaded Dll/ +Unicode Release Multithreaded/ +Unicode Release/ +Win32/ bin/ +ideas/ ipch/ lib/ +perf_test/ +projects/util/vc10-generated/ +scripts/internal/ +x64/ # directories (by pattern) +/include-*/ + # files (by name) .DS_Store +.classpath +.env.development.local +.env.local +.env.production.local +.env.test.local +.ruby-version +.ruby-version-exclusions +.svnignore +.svnignore-at-root +.update_deps +/--include +/--src +/-include +/-src +/__pycache__ +/dox +/examples/bin +/examples/c/bin +/examples/c/lib +/examples/cpp/bin +/examples/cpp/lib +/examples/lib +/node_modules +build/CMakeCache.txt +build/makefile.tmpl +build/makefile.tools.xml +build/shwild.tmplgen +include/fastformat/internal/dos2unix.has.been.performed +include/pantheios/internal/dos2unix.has.been.performed +include/stlsoft/dos2unix.has.been.performed +include/stlsoft/internal/dos2unix.has.been.performed +list_changes.cmd +logging-bailout.txt +prepare.cmd +sh.exe.stackdump +test/testpatterns.orj +test/tests-plan.txt +tidydir.cmd +update_deps.cmd # files (by pattern) -*~ +*.*~ +*.???_obj +*.VC.db +*.VC.opendb *.a +*.app +*.aps +*.b64 +*.bak +*.chm +*.class +*.csproj*user +*.d +*.diff *.dll +*.dsp *.dylib *.exe *.gch +*.gem +*.idb +*.ilk +*.iobj +*.ipch +*.ipdb +*.la +*.lai *.lib +*.lo +*.log +*.ncb *.o *.obj +*.opensdf +*.opt +*.org *.out *.pch *.pdb +*.pyc +*.rar +*.res +*.sbr +*.scc +*.sdf +*.slo *.so +*.suo *.sw[ponm] +*.swp +*.test +*.tlog *.tmp +*.unsuccessfulbuild +*.vc71.sln +*.vc8.sln +*.vc9.sln +*.vcproj*.user +*.vcproj*user +*.vcxproj*.user +*.vcxproj*user +*.xcuserstate *.zip +*~ +/build/*.zip +/build/ar* +/build/bc5* +/build/como* +/build/cw* +/build/gcc3* +/build/gcc4* +/build/icl* +/build/vc5* +RCa0* +RCb0* +build/*.tmpl +build/*.tmplgen +build/*.tools.xml +npm-debug.log* +yarn-debug.log* +yarn-error.log* diff --git a/templates/vscode/c/settings.json b/templates/vscode/c/settings.json index a20fc3c..6a0da10 100644 --- a/templates/vscode/c/settings.json +++ b/templates/vscode/c/settings.json @@ -70,6 +70,11 @@ "editor.rulers": [ 76 ], "editor.tabSize": 2, "files.associations": { + "*.gemspec": "ruby", + "*.mdoc": "troff", + "*.roff": "troff", + "Gemfile": "ruby", + "Rakefile": "ruby", "__bit_reference": "cpp", "__bits": "cpp", "__config": "cpp", @@ -90,13 +95,17 @@ "__tuple": "cpp", "__verbose_abort": "cpp", "algorithm": "cpp", + "api.h": "c", "array": "cpp", "atomic": "cpp", + "auto_buffer.h": "c", "bit": "cpp", "bitset": "cpp", "cctype": "cpp", "charconv": "cpp", "chrono": "cpp", + "clasp.h": "c", + "cli_helpers.h": "c", "clocale": "cpp", "cmath": "cpp", "compare": "cpp", @@ -123,6 +132,7 @@ "functional": "cpp", "implicit_link.h": "c", "initializer_list": "cpp", + "invoke.h": "c", "io.h": "c", "iomanip": "cpp", "ios": "cpp", @@ -133,29 +143,39 @@ "limits": "cpp", "list": "cpp", "locale": "cpp", + "main.h": "c", "map": "cpp", "memory": "cpp", "memory_resource": "cpp", "mutex": "cpp", + "net_helpers.h": "c", "new": "cpp", "numbers": "cpp", "numeric": "cpp", "optional": "cpp", "ostream": "cpp", + "path_functions.h": "c", "print": "cpp", "queue": "cpp", "random": "cpp", "ranges": "cpp", "ratio": "cpp", + "rc.h": "c", + "recls.h": "c", + "result_codes_.h": "c", "semaphore": "cpp", "set": "cpp", "setenv.h": "c", "shwild.h": "c", + "sleep_functions.h": "c", "span": "cpp", "sstream": "cpp", "stack": "cpp", + "stdatomic.h": "c", + "stdbool.h": "c", "stdexcept": "cpp", "stdio.h": "c", + "stock.h": "c", "stop_token": "cpp", "streambuf": "cpp", "string": "cpp", @@ -164,6 +184,7 @@ "terse-api.h": "c", "text_encoding": "cpp", "thread": "cpp", + "trace.h": "c", "tuple": "cpp", "type_traits": "cpp", "typeinfo": "cpp", @@ -174,6 +195,7 @@ "utility": "cpp", "variant": "cpp", "vector": "cpp", + "williamscrc.h": "c", "xfacet": "cpp", "xhash": "cpp", "xiosbase": "cpp", diff --git a/templates/vscode/c_cxx/settings.json b/templates/vscode/c_cxx/settings.json index a20fc3c..6aa78f6 100644 --- a/templates/vscode/c_cxx/settings.json +++ b/templates/vscode/c_cxx/settings.json @@ -8,7 +8,7 @@ "editor.defaultFormatter": "ms-vscode.cpptools", "editor.formatOnSave": true, "editor.insertSpaces": true, - "editor.rulers": [ 60, 64, 68, 72, 76 ], + "editor.rulers": [ 60, 64, 68, 72, 76, 120 ], "editor.tabSize": 4, }, "[cmake]": { @@ -19,7 +19,7 @@ "editor.defaultFormatter": "ms-vscode.cpptools", "editor.formatOnSave": true, "editor.insertSpaces": true, - "editor.rulers": [ 60, 64, 68, 72, 76 ], + "editor.rulers": [ 60, 64, 68, 72, 76, 120 ], "editor.tabSize": 4, }, "[json]": { @@ -38,6 +38,7 @@ }, "[ruby]": { "editor.insertSpaces": true, + "editor.rulers": [ 60, 76 ], "editor.tabSize": 2, }, "[shellscript]": { @@ -70,6 +71,11 @@ "editor.rulers": [ 76 ], "editor.tabSize": 2, "files.associations": { + "*.gemspec": "ruby", + "*.mdoc": "troff", + "*.roff": "troff", + "Gemfile": "ruby", + "Rakefile": "ruby", "__bit_reference": "cpp", "__bits": "cpp", "__config": "cpp", @@ -90,13 +96,17 @@ "__tuple": "cpp", "__verbose_abort": "cpp", "algorithm": "cpp", + "api.h": "c", "array": "cpp", "atomic": "cpp", + "auto_buffer.h": "c", "bit": "cpp", "bitset": "cpp", "cctype": "cpp", "charconv": "cpp", "chrono": "cpp", + "clasp.h": "c", + "cli_helpers.h": "c", "clocale": "cpp", "cmath": "cpp", "compare": "cpp", @@ -123,6 +133,7 @@ "functional": "cpp", "implicit_link.h": "c", "initializer_list": "cpp", + "invoke.h": "c", "io.h": "c", "iomanip": "cpp", "ios": "cpp", @@ -133,29 +144,39 @@ "limits": "cpp", "list": "cpp", "locale": "cpp", + "main.h": "c", "map": "cpp", "memory": "cpp", "memory_resource": "cpp", "mutex": "cpp", + "net_helpers.h": "c", "new": "cpp", "numbers": "cpp", "numeric": "cpp", "optional": "cpp", "ostream": "cpp", + "path_functions.h": "c", "print": "cpp", "queue": "cpp", "random": "cpp", "ranges": "cpp", "ratio": "cpp", + "rc.h": "c", + "recls.h": "c", + "result_codes_.h": "c", "semaphore": "cpp", "set": "cpp", "setenv.h": "c", "shwild.h": "c", + "sleep_functions.h": "c", "span": "cpp", "sstream": "cpp", "stack": "cpp", + "stdatomic.h": "c", + "stdbool.h": "c", "stdexcept": "cpp", "stdio.h": "c", + "stock.h": "c", "stop_token": "cpp", "streambuf": "cpp", "string": "cpp", @@ -164,6 +185,7 @@ "terse-api.h": "c", "text_encoding": "cpp", "thread": "cpp", + "trace.h": "c", "tuple": "cpp", "type_traits": "cpp", "typeinfo": "cpp", @@ -174,6 +196,7 @@ "utility": "cpp", "variant": "cpp", "vector": "cpp", + "williamscrc.h": "c", "xfacet": "cpp", "xhash": "cpp", "xiosbase": "cpp", diff --git a/templates/vscode/cxx/settings.json b/templates/vscode/cxx/settings.json index a20fc3c..6a0da10 100644 --- a/templates/vscode/cxx/settings.json +++ b/templates/vscode/cxx/settings.json @@ -70,6 +70,11 @@ "editor.rulers": [ 76 ], "editor.tabSize": 2, "files.associations": { + "*.gemspec": "ruby", + "*.mdoc": "troff", + "*.roff": "troff", + "Gemfile": "ruby", + "Rakefile": "ruby", "__bit_reference": "cpp", "__bits": "cpp", "__config": "cpp", @@ -90,13 +95,17 @@ "__tuple": "cpp", "__verbose_abort": "cpp", "algorithm": "cpp", + "api.h": "c", "array": "cpp", "atomic": "cpp", + "auto_buffer.h": "c", "bit": "cpp", "bitset": "cpp", "cctype": "cpp", "charconv": "cpp", "chrono": "cpp", + "clasp.h": "c", + "cli_helpers.h": "c", "clocale": "cpp", "cmath": "cpp", "compare": "cpp", @@ -123,6 +132,7 @@ "functional": "cpp", "implicit_link.h": "c", "initializer_list": "cpp", + "invoke.h": "c", "io.h": "c", "iomanip": "cpp", "ios": "cpp", @@ -133,29 +143,39 @@ "limits": "cpp", "list": "cpp", "locale": "cpp", + "main.h": "c", "map": "cpp", "memory": "cpp", "memory_resource": "cpp", "mutex": "cpp", + "net_helpers.h": "c", "new": "cpp", "numbers": "cpp", "numeric": "cpp", "optional": "cpp", "ostream": "cpp", + "path_functions.h": "c", "print": "cpp", "queue": "cpp", "random": "cpp", "ranges": "cpp", "ratio": "cpp", + "rc.h": "c", + "recls.h": "c", + "result_codes_.h": "c", "semaphore": "cpp", "set": "cpp", "setenv.h": "c", "shwild.h": "c", + "sleep_functions.h": "c", "span": "cpp", "sstream": "cpp", "stack": "cpp", + "stdatomic.h": "c", + "stdbool.h": "c", "stdexcept": "cpp", "stdio.h": "c", + "stock.h": "c", "stop_token": "cpp", "streambuf": "cpp", "string": "cpp", @@ -164,6 +184,7 @@ "terse-api.h": "c", "text_encoding": "cpp", "thread": "cpp", + "trace.h": "c", "tuple": "cpp", "type_traits": "cpp", "typeinfo": "cpp", @@ -174,6 +195,7 @@ "utility": "cpp", "variant": "cpp", "vector": "cpp", + "williamscrc.h": "c", "xfacet": "cpp", "xhash": "cpp", "xiosbase": "cpp", diff --git a/templates/vscode/generic/settings.json b/templates/vscode/generic/settings.json index d693b94..7b522c7 100644 --- a/templates/vscode/generic/settings.json +++ b/templates/vscode/generic/settings.json @@ -246,6 +246,8 @@ "random": "cpp", "ranges": "cpp", "ratio": "cpp", + "rc.h": "c", + "result_codes_.h": "c", "semaphore": "cpp", "set": "cpp", "setenv.h": "c",