Compare commits
2
Commits
31fbef35d4
..
next
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
8976a64832 | ||
|
|
4666af1cc8 |
No files matched your search
@@ -102,9 +102,9 @@ Future improvements under consideration:
|
|||||||
- Author & maintainer: **sneak** – <sneak@sneak.berlin>
|
- Author & maintainer: **sneak** – <sneak@sneak.berlin>
|
||||||
- Issues / PRs: <https://git.eeqj.de/sneak/attrsum/>
|
- Issues / PRs: <https://git.eeqj.de/sneak/attrsum/>
|
||||||
- Code must pass `make check`, which runs the tests and golangci-lint as phases
|
- Code must pass `make check`, which runs the tests and golangci-lint as phases
|
||||||
of the `Dockerfile` (Docker is required) and checks formatting with `gofmt`
|
of the `Dockerfile` (Docker is required) and checks formatting with `gofmt -s`
|
||||||
for Go and prettier for Markdown. `make bootstrap` installs prettier, and
|
and goimports for Go and prettier for Markdown. `make bootstrap` installs
|
||||||
`make fmt` fixes what the check reports.
|
goimports and prettier, and `make fmt` fixes what the check reports.
|
||||||
- No CLA; contributions are under WTFPL v2.
|
- No CLA; contributions are under WTFPL v2.
|
||||||
|
|
||||||
---
|
---
|
||||||
|
|||||||
@@ -28,6 +28,9 @@ TODO, License exist; Description, Entrypoints, Design, Author are missing)
|
|||||||
change; prettier is pinned in `package.json` and `yarn.lock`, and
|
change; prettier is pinned in `package.json` and `yarn.lock`, and
|
||||||
`script/bootstrap` installs it, along with the pinned node and yarn when the
|
`script/bootstrap` installs it, along with the pinned node and yarn when the
|
||||||
yarn on hand is not the pinned version; the Markdown files reformatted once
|
yarn on hand is not the pinned version; the Markdown files reformatted once
|
||||||
|
- 2026-10-06: `script/fmt-check` checks what `script/fmt` writes: it fails and
|
||||||
|
lists the files when `gofmt -s` or goimports would change one, so a file that
|
||||||
|
passes `make check` no longer changes on the next `make fmt`
|
||||||
- 2026-10-06: canonical files re-vendored from `sneak/prompts` at `dd4027b`:
|
- 2026-10-06: canonical files re-vendored from `sneak/prompts` at `dd4027b`:
|
||||||
`REPO_POLICIES.md` and `.editorconfig` added; `.dockerignore`, `.gitignore`,
|
`REPO_POLICIES.md` and `.editorconfig` added; `.dockerignore`, `.gitignore`,
|
||||||
`.golangci.yml` and the workflow refreshed, keeping this repo's own entries
|
`.golangci.yml` and the workflow refreshed, keeping this repo's own entries
|
||||||
|
|||||||
+1
-1
@@ -1,5 +1,5 @@
|
|||||||
{
|
{
|
||||||
"license": "MIT",
|
"private": true,
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"prettier": "3.8.1"
|
"prettier": "3.8.1"
|
||||||
}
|
}
|
||||||
|
|||||||
+8
-3
@@ -27,10 +27,15 @@ run_yarn() {
|
|||||||
|
|
||||||
main() {
|
main() {
|
||||||
cd "$ROOT"
|
cd "$ROOT"
|
||||||
files="$(gofmt -l .)"
|
# script/bootstrap installs goimports into Go's bin directory, which
|
||||||
|
# need not be on PATH.
|
||||||
|
gobin="$(go env GOBIN)"
|
||||||
|
[ -n "$gobin" ] || gobin="$(go env GOPATH)/bin"
|
||||||
|
PATH="$gobin:$PATH"
|
||||||
|
files="$(gofmt -s -l .; goimports -l .)"
|
||||||
if [ -n "$files" ]; then
|
if [ -n "$files" ]; then
|
||||||
echo "gofmt: files not formatted:" >&2
|
echo "files that make fmt would change:" >&2
|
||||||
echo "$files" >&2
|
echo "$files" | sort -u >&2
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
run_yarn run prettier --check '**/*.md' --tab-width 4 --prose-wrap always
|
run_yarn run prettier --check '**/*.md' --tab-width 4 --prose-wrap always
|
||||||
|
|||||||
Reference in new issue
Block a user