Java Collections Lab Setup
Setup
Open your Terminal application and navigate to your ~/code/ga/labs directory.
cd ~/code/ga/labs
Clone the Java Collections Lab starter code repository with this command:
git clone https://git.generalassemb.ly/modular-curriculum-all-courses/java-collections-lab-starter.git java-collections-lab
💡 The
java-collections-labat the end of this command will place the contents of thejava-collections-lab-starterrepo into a directory namedjava-collections-lab.
Next, cd into the newly created directory:
cd java-collections-lab
You don’t want GA commits on your work, so remove the existing Git information from this starter code:
rm -rf .git
To get this work to GitHub, initialize a new Git repository:
git init
git add .
git commit -m "initial commit"
Make a new repository on your personal GitHub account named java-collections-lab.
Link your local work to your remote GitHub repo:
git remote add origin https://github.com/<github-username>/java-collections-lab.git
git push origin main
🚨 Do not copy the above command. It will not work. Your GitHub username will replace<github-username>(including the<and>) in the URL above.
Open IntelliJ IDEA Community Edition and open the project by selecting the Open option on the launch screen.
Next, navigate to the java-collections-lab directory you just created and open the project.
Trust the project if you are prompted.
Running the Tests
This lab includes a set of tests to help you verify your work. To run the tests, right-click on the src/test/java directory and select Run ‘All Tests’.