aplus/README.md

55 lines
1.6 KiB
Markdown
Raw Permalink Normal View History

# A+Attendance CLI
2023-10-27 16:16:42 -04:00
This is a CLI utility initially created for students at Florida Polytechnic University to submit their A+ attendance codes, but can be used for other
universities using Canvas and A+Attendance.
## Building/Installing
To compile this program, you need `go` installed as well as need to set two
environment variables in your shell's configuration file (like `~/.profile` or it's rc file) for your Canvas instance URL and your account's API key.
### Getting an API key
When logged into your university's Canvas site, go to Account -> Settings -> New Access Token -> (give any name or expiration date) -> store the Token somewhere.
### Setting the Environment Variables
In your shell's configuration file, add:
```sh
export CANVAS_INSTANCE="https://youruniversityhere.instructure.com"
export CANVAS_API_KEY="the_canvas_access_token_you_stored_somewhere"
# below not needed if go is already setup
export GOPATH=$HOME/.local/go
export GOBIN=$GOPATH/bin
export PATH=$PATH:$GOBIN
```
### Installing
Simply run `go install codeberg.org/flpolyaplus/aplus@latest`.
## Usage
### Show help message
`aplus --help`
### List all courses and canvas course codes
2024-01-16 15:04:45 -05:00
`aplus --list-all`
### List favorite courses and canvas course codes
2024-01-16 15:04:45 -05:00
`aplus --list-favorites`
### Enter code for a specified course
2024-01-16 15:04:45 -05:00
`aplus --code <code> --course <canvas_course_number>`
If no course is specified, the code is tried on all active courses.
### Show timetable for a specified course
`aplus --timetable --course <canvas_course_number>`
2024-01-16 15:04:45 -05:00
## Mirrors
[Codeberg](https://codeberg.org/flpolyaplus/aplus/)
[Gitea (vineetk)](https://gitea.vineetk.net/flpolyaplus/aplus/)