Convert "internal" levels to new level format

This commit is contained in:
Sebastian Morr 2020-10-12 18:54:27 +02:00
parent 613b1b9852
commit 53a6885ef9
108 changed files with 727 additions and 382 deletions

View file

@ -1,3 +1,25 @@
[description]
Trees can also point to other trees! This way, they can describe nested directory structures.
When you add a file inside of a directory to the index, and then call `git write-tree`, it will create a nested tree for the directory, and attach the blob to it.
To solve this level, build a little stick figure, as shown on the left - a tree that points to two blobs, as well to a tree that points to two blobs.
[setup]
[setup goal]
echo "I'm the left arm" > arm1
echo "I'm the right arm" > arm2
mkdir hip
echo "I'm the left leg" > hip/leg1
echo "I'm the right leg" > hip/leg2
git add .
git write-tree
[win]
TREES=$(git cat-file --batch-check='%(objectname) %(objecttype)' --batch-all-objects | grep tree | cut -f1 -d" ")
for OUTER_TREE in $TREES; do

View file

@ -1,5 +0,0 @@
Trees can also point to other trees! This way, they can describe nested directory structures.
When you add a file inside of a directory to the index, and then call `git write-tree`, it will create a nested tree for the directory, and attach the blob to it.
To solve this level, build a little stick figure, as shown on the left - a tree that points to two blobs, as well to a tree that points to two blobs.

View file

@ -1,7 +0,0 @@
echo "I'm the left arm" > arm1
echo "I'm the right arm" > arm2
mkdir hip
echo "I'm the left leg" > hip/leg1
echo "I'm the right leg" > hip/leg2
git add .
git write-tree