Convert gitgram/ and aitimemachine/ from embedded git repos (which showed as opaque submodule gitlinks on GitHub) into fully-tracked first-party content. AITM now merges its 7 vendored repos as first-party engines: - memory: beads (Go task DAG) + context7 (docs SDK), unified into saved_contexts - git: vendored C git (bundled binary) + gitnexus (in-process code intelligence) - agentic: a2a (@a2a-js/sdk) + pal (AITM-managed Python subprocess) Includes the full session's product build: Gitgram web/mobile/backend features, AITM website/CLI/MCP, the unified memory layer, engine build tooling (scripts/build-engines.sh, Dockerfile, CI), docs (README, ENGINES.md, ARCHITECTURE.md), and extensive test suites. Build artifacts, node_modules, external/, and gemini-cli are gitignored. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
135 lines
3.2 KiB
Bash
Executable File
135 lines
3.2 KiB
Bash
Executable File
#!/bin/sh
|
|
|
|
test_description='tests for ref^{stuff}'
|
|
|
|
GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME=main
|
|
export GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME
|
|
|
|
. ./test-lib.sh
|
|
|
|
test_expect_success 'setup' '
|
|
echo blob >a-blob &&
|
|
git tag -a -m blob blob-tag $(git hash-object -w a-blob) &&
|
|
mkdir a-tree &&
|
|
echo moreblobs >a-tree/another-blob &&
|
|
git add . &&
|
|
TREE_SHA1=$(git write-tree) &&
|
|
git tag -a -m tree tree-tag "$TREE_SHA1" &&
|
|
git commit -m Initial &&
|
|
git tag -a -m commit commit-tag &&
|
|
git branch ref &&
|
|
git checkout main &&
|
|
echo modified >>a-blob &&
|
|
git add -u &&
|
|
git commit -m Modified &&
|
|
git branch modref &&
|
|
echo changed! >>a-blob &&
|
|
git add -u &&
|
|
git commit -m !Exp &&
|
|
git branch expref &&
|
|
echo changed >>a-blob &&
|
|
git add -u &&
|
|
git commit -m Changed &&
|
|
echo changed-again >>a-blob &&
|
|
git add -u &&
|
|
git commit -m Changed-again
|
|
'
|
|
|
|
test_expect_success 'ref^{non-existent}' '
|
|
test_must_fail git rev-parse ref^{non-existent}
|
|
'
|
|
|
|
test_expect_success 'ref^{}' '
|
|
git rev-parse ref >expected &&
|
|
git rev-parse ref^{} >actual &&
|
|
test_cmp expected actual &&
|
|
git rev-parse commit-tag^{} >actual &&
|
|
test_cmp expected actual
|
|
'
|
|
|
|
test_expect_success 'ref^{commit}' '
|
|
git rev-parse ref >expected &&
|
|
git rev-parse ref^{commit} >actual &&
|
|
test_cmp expected actual &&
|
|
git rev-parse commit-tag^{commit} >actual &&
|
|
test_cmp expected actual &&
|
|
test_must_fail git rev-parse tree-tag^{commit} &&
|
|
test_must_fail git rev-parse blob-tag^{commit}
|
|
'
|
|
|
|
test_expect_success 'ref^{tree}' '
|
|
echo $TREE_SHA1 >expected &&
|
|
git rev-parse ref^{tree} >actual &&
|
|
test_cmp expected actual &&
|
|
git rev-parse commit-tag^{tree} >actual &&
|
|
test_cmp expected actual &&
|
|
git rev-parse tree-tag^{tree} >actual &&
|
|
test_cmp expected actual &&
|
|
test_must_fail git rev-parse blob-tag^{tree}
|
|
'
|
|
|
|
test_expect_success 'ref^{tag}' '
|
|
test_must_fail git rev-parse HEAD^{tag} &&
|
|
git rev-parse commit-tag >expected &&
|
|
git rev-parse commit-tag^{tag} >actual &&
|
|
test_cmp expected actual
|
|
'
|
|
|
|
test_expect_success 'ref^{/.}' '
|
|
git rev-parse main >expected &&
|
|
git rev-parse main^{/.} >actual &&
|
|
test_cmp expected actual
|
|
'
|
|
|
|
test_expect_success 'ref^{/non-existent}' '
|
|
test_must_fail git rev-parse main^{/non-existent}
|
|
'
|
|
|
|
test_expect_success 'ref^{/Initial}' '
|
|
git rev-parse ref >expected &&
|
|
git rev-parse main^{/Initial} >actual &&
|
|
test_cmp expected actual
|
|
'
|
|
|
|
test_expect_success 'ref^{/!Exp}' '
|
|
test_must_fail git rev-parse main^{/!Exp}
|
|
'
|
|
|
|
test_expect_success 'ref^{/!}' '
|
|
test_must_fail git rev-parse main^{/!}
|
|
'
|
|
|
|
test_expect_success 'ref^{/!!Exp}' '
|
|
git rev-parse expref >expected &&
|
|
git rev-parse main^{/!!Exp} >actual &&
|
|
test_cmp expected actual
|
|
'
|
|
|
|
test_expect_success 'ref^{/!-}' '
|
|
test_must_fail git rev-parse main^{/!-}
|
|
'
|
|
|
|
test_expect_success 'ref^{/!-.}' '
|
|
test_must_fail git rev-parse main^{/!-.}
|
|
'
|
|
|
|
test_expect_success 'ref^{/!-non-existent}' '
|
|
git rev-parse main >expected &&
|
|
git rev-parse main^{/!-non-existent} >actual &&
|
|
test_cmp expected actual
|
|
'
|
|
|
|
test_expect_success 'ref^{/!-Changed}' '
|
|
git rev-parse expref >expected &&
|
|
git rev-parse main^{/!-Changed} >actual &&
|
|
test_cmp expected actual
|
|
'
|
|
|
|
test_expect_success 'ref^{/!-!Exp}' '
|
|
git rev-parse modref >expected &&
|
|
git rev-parse expref^{/!-!Exp} >actual &&
|
|
test_cmp expected actual
|
|
'
|
|
|
|
test_done
|