chore: cleanup — untrack binaries, consolidate Go dirs, dedupe tools
- Untrack and delete compiled binaries (tarsum, gosoft.exe, rust uniq/uniq2);
ignore build outputs (dist/, bin/, *.exe, *.test, .ruff_cache/)
- Merge tools/go/ and projects/go-tools/go/ into projects/go-tools/<name>/
- Fix goipgrep .gitignore: bare 'ipgrep' pattern was ignoring cmd/ipgrep/,
so the main entrypoint was never tracked; now anchored to /ipgrep
- Archive duplicate implementations to archive/experimental/{rust,go}/
(uniq, between, tarsum rewrites); canonical versions stay in tools/
- Update README tool catalog to match new layout
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
Executable
+26
@@ -0,0 +1,26 @@
|
||||
#!/usr/bin/env sh
|
||||
set -eu
|
||||
|
||||
cd "$(dirname "$0")/.."
|
||||
|
||||
mkdir -p dist
|
||||
|
||||
VERSION="${VERSION:-dev}"
|
||||
COMMIT="${COMMIT:-$(git rev-parse --short HEAD 2>/dev/null || echo unknown)}"
|
||||
DATE="${DATE:-$(date -u +%Y-%m-%dT%H:%M:%SZ)}"
|
||||
|
||||
EXTRA_LDFLAGS=""
|
||||
GOOS="$(go env GOOS)"
|
||||
if [ "$GOOS" = "darwin" ]; then
|
||||
# Some macOS environments treat missing LC_UUID as fatal; external linkmode
|
||||
# ensures the toolchain emits LC_UUID.
|
||||
EXTRA_LDFLAGS="-linkmode=external"
|
||||
fi
|
||||
|
||||
go build \
|
||||
-trimpath \
|
||||
-ldflags "-s -w ${EXTRA_LDFLAGS} -X main.version=${VERSION} -X main.commit=${COMMIT} -X main.date=${DATE}" \
|
||||
-o dist/ipgrep \
|
||||
./cmd/ipgrep
|
||||
|
||||
echo "built dist/ipgrep"
|
||||
Reference in New Issue
Block a user