Setting Up Your Environment
This guide walks you through getting the CSE320 template repository from CodeGrade and setting up your development environment.Prerequisites
Before you begin, ensure you have:- Access to CodeGrade for CSE320
- A Linux development environment (Linux Mint recommended for official course environment)
- GCC compiler and build tools installed
- Git version control system
The official course environment is Linux Mint. While you can develop on other systems, your code must compile and run correctly in the Linux Mint environment used for grading.
Getting the Template from CodeGrade
Access CodeGrade
Log into CodeGrade through your course portal. You should see the CSE320 course with available assignments.
Create Your Repository
When you access an assignment in CodeGrade, it will create a personal git repository for you based on the template. This repository is linked to CodeGrade for automated testing.You’ll receive a git repository URL that looks like:
Clone the Repository
Clone your repository to your local development machine:Replace the URL with your actual repository URL from CodeGrade.
Installing Required Tools
Make sure you have the necessary development tools installed.On Linux Mint / Ubuntu / Debian
Verify Installation
Understanding CodeGrade Integration
How CodeGrade Testing Works
-
Automatic Testing: Every
git pushtriggers CodeGrade to:- Clone your repository
- Compile your code
- Run the provided test cases
- Display results in your CodeGrade dashboard
- Continuous Feedback: You can push as many times as you want before the deadline. Use this to verify your code compiles and passes basic tests.
- Final Grading: After the submission deadline, more comprehensive test cases are run that are NOT visible to you during development.
Recommended Workflow
Reading the Assignment Specifications
Each homework directory contains a comprehensive README.md file with:- Complete specifications for all functions
- Data structure definitions
- Algorithm explanations
- Example hex dumps and walkthroughs
- Output format requirements
- Allowed and disallowed libraries
Study the References
The READMEs link to external specifications:
- PNG Homework: PNG Specification
- ZLIB Homework: RFC 1951 (DEFLATE), RFC 1952 (GZIP)
- C Programming: Beej’s Guide to C
Important Files to NOT Modify
Git Best Practices
What to Commit
What NOT to Commit
The.gitignore file is pre-configured to exclude:
- Compiled binaries (
bin/) - Object files (
build/) - Editor temporary files
- Core dumps
Commit Message Guidelines
Write clear, descriptive commit messages:Next Steps
Now that your environment is set up:Build the Project
Learn how to compile and build the assignments
Run Tests
Understand how to run and interpret test results
Troubleshooting
”Criterion not found” Error
If you get linking errors about Criterion:“zlib not found” Error (PNG Homework)
Permission Denied on Git Push
Make sure you’ve configured git credentials:CodeGrade Not Running Tests
If CodeGrade doesn’t run tests after pushing:- Check that you pushed to the correct branch (usually
mainormaster) - Verify your code compiles without errors
- Check the CodeGrade dashboard for error messages
- Ensure you haven’t modified “DO NOT MODIFY” files in incompatible ways