Interplane page as plain text, for reading tools and agents. English is the reference text: translate it with your own tool. Text in backticks and in ``` blocks (commands, fingerprints, file names) and link targets in <...> are exact: copy them, never translate them. Page: /drakestapleton/git/blob/master/t/t1009-read-tree-new-index.sh # git [Ported from github.com/git/git] Sync with Git 2.56.1 Brought by drakestapleton Sign in to star 0 stars 0 watching About Files History Releases Proposed changes Issues For developers branch `master` Branches Tags History `git / t / t1009-read-tree-new-index.sh` 28 lines ยท 510 bytes Raw Blame History 1 #!/bin/sh 2 3 test_description='test read-tree into a fresh index file' 4 5 GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME=main 6 export GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME 7 8 . ./test-lib.sh 9 10 test_expect_success setup ' 11 echo one >a && 12 git add a && 13 git commit -m initial 14 ' 15 16 test_expect_success 'non-existent index file' ' 17 rm -f new-index && 18 GIT_INDEX_FILE=new-index git read-tree main 19 ' 20 21 test_expect_success 'empty index file' ' 22 rm -f new-index && 23 > new-index && 24 GIT_INDEX_FILE=new-index git read-tree main 25 ' 26 27 test_done 28