This project was developed as part of the fulfillment of Checkpoint 1 in the Python Learning Path. Amity is a command line application used to allocate office and room space.
create_room <room_name>...
- Creates a room in Amity. This command can create as many rooms as possible by specifying multiple room namesadd_person <person_name> <FELLOW|STAFF>
- Add a person to the system and allocates the person to a random roomreallocate_person <person_identifier> <new_room_name>
- Reallocate the person with person withperson_identifier
tonew_room_name
load_people
- Adds people to rooms from a text fileprint_allocations [-o=filename]
- Prints a list of allocations onto the screen. Specifying the optional -o option here outputs the information to the text file providedprint_unallocated [-o=filename]
- Prints a list of unallocated people to the screen. Specifying the -o option here outputs the information to the text file providedprint_room <room_name>
- Prints the names of the people inroom_name
on the screensave_state [--db=sqlite_database]
- Persists all the data stored in the app to a SQLite database. Specifying the --db parameter explicitly stores the data in the sqlite_database specified.load_state <sqlite_database>
- Loads data from a database into the application.
- Download & Install Python
- Head over to the Python Downloads Site and download a version compatible with your operating system
- To confirm that you have successfully installed Python:
- Open the Command Propmpt on Windows or Terminal on Mac/Linux
- Type python
- If the Python installation was successfull you the Python version will be printed on your screen and the python REPL will start
- Clone the repository to your personal computer to any folder
- On GitHub, go to the main page of the repository Amity
- On your right, click the green button 'Clone or download'
- Copy the URL
- Enter the terminal on Mac/Linux or Git Bash on Windows
- Type
git clone
and paste the URL you copied from GitHub - Press Enter to complete the cloning process
- Virtual Environment Installation
- Install the virtual environment by typing:
pip install virtualenv
on your terminal
- Install the virtual environment by typing:
- Install the required modules
- Inside the directory where you cloned the repository run
pip install -r requirements.txt
- Inside the directory where you cloned the repository run
- Inside the application folder run the app.py file:
- On the terminal type
python app.py
to start the application