fix: simplify verification for module 1

This commit is contained in:
Bjarke Sporring
2026-01-04 15:25:52 +01:00
parent 2b3ea7ed36
commit 4a47d8b36e
2 changed files with 51 additions and 54 deletions

View File

@@ -24,15 +24,19 @@ This will create a directory called `challenge` with some files that need to be
### Your Task
Your goal is to commit both `welcome.txt` and `instructions.txt` to a git repository. Here's a suggested approach:
1. Navigate into the `challenge` directory: `cd challenge`
2. **Initialize a new git repository**: `git init` (this is your first step!)
3. Check the status of your repository: `git status`
4. Stage the file `welcome.txt`: `git add welcome.txt`
5. Create a commit with the message "Add welcome file": `git commit -m "Add welcome file"`
6. Stage the file `instructions.txt`: `git add instructions.txt`
7. Create a commit with the message "Add instructions": `git commit -m "Add instructions"`
4. Stage the files you want to commit: `git add welcome.txt` (or `git add .` to stage all files)
5. Create a commit: `git commit -m "Your commit message"`
6. Verify both files are committed: `git ls-tree -r HEAD --name-only`
**Note**: The challenge directory is NOT a git repository until you run `git init`. This is intentional - you're learning to start from scratch!
**Important Notes**:
- The challenge directory is NOT a git repository until you run `git init`. This is intentional - you're learning to start from scratch!
- You can commit both files together in one commit, or separately in multiple commits - it's up to you!
- The verification script checks that both files are committed, not the specific commit messages or order
### Key Concepts
@@ -44,10 +48,13 @@ This will create a directory called `challenge` with some files that need to be
### Useful Commands
```bash
git init # Initialize a new git repository
git status # Show the working tree status
git add <file> # Stage a file for commit
git commit -m "<message>" # Create a commit with a message
git init # Initialize a new git repository
git status # Show the working tree status
git add <file> # Stage a specific file for commit
git add . # Stage all files in current directory
git commit -m "<message>" # Create a commit with a message
git ls-tree -r HEAD --name-only # List all files in the latest commit
git log # View commit history
```
### Verification
@@ -59,3 +66,13 @@ Once you think you've completed the challenge, run:
```
This will check if you've successfully completed all the steps.
### Need to Start Over?
If you want to reset the challenge and start fresh, run:
```powershell
.\reset.ps1
```
This will remove your challenge directory and set up a new one.