Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/juanrcoder/holbertonschool-airbnb_clone
https://github.com/juanrcoder/holbertonschool-airbnb_clone
Last synced: 8 days ago
JSON representation
- Host: GitHub
- URL: https://github.com/juanrcoder/holbertonschool-airbnb_clone
- Owner: juanRCoder
- Created: 2023-08-14T17:02:12.000Z (over 1 year ago)
- Default Branch: master
- Last Pushed: 2023-08-16T21:08:23.000Z (over 1 year ago)
- Last Synced: 2023-08-16T22:26:14.648Z (over 1 year ago)
- Language: HTML
- Size: 64.5 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# AIRBNB clone - The console :city_sunrise:
## Project Description:
Welcome to the exciting Airbnb clone project! In this initial phase, we have developed the backend and a console application in Python using the `cmd` and `json` modules.
Data is stored as Python objects and saved in JSON format for easy management. Our replica offers basic functionalities such as searching and booking accommodations,
as well as interacting with users. This project lays the foundation for future enhancements and expansions.## Description of the command interpreter:speech_balloon:
The command interpreter is a Bash-like interface specifically designed for the Airbnb clone project. It accepts a limited
number of predefined commands created especially for the usage of the AirBnB website. It functions as the frontend of the
web application, allowing users to interact with the Python-based backend using object-oriented programming (OOP).## Some of the commands available are:floppy_disk:
- quit - exit
- help
- create
- show
- destroy
- all
- update## Command Interpreter Description:computer:
|Command| Description |
|--|--|
| **quit or EOF** | Exits the program |
| **Usage** | By itself |
| **-----** | **-----** |
| **help** | Provides a text describing how to use a command. |
| **Usage** | By itself --or-- **help ** |
| **-----** | **-----** |
| **create** | Creates a new instance of a valid `Class`, saves it (to the JSON file) and prints the `id`. Valid classes are: BaseModel, User, State, City, Amenity, Place, Review. |
| **Usage** | **create **|
| **-----** | **-----** |
| **show** | Prints the string representation of an instance based on the class name and `id` |
| **Usage** | **show ** --or-- **.show()**|
| **-----** | **-----** |
| **destroy** | Deletes an instance based on the class name and `id` (saves the change into a JSON file). |
| **Usage** | **destroy ** --or-- **.destroy()** |
| **-----** | **-----** |
| **all** | Prints all string representation of all instances based or not on the class name. |
| **Usage** | By itself or **all ** --or-- **.all()** |
| **-----** | **-----** |
| **update** | Updates an instance based on the class name and `id` by adding or updating attribute (saves the changes into a JSON file). |
| **Usage** | **update ""** ---or--- **.update(, , )** --or-- **.update(, )**|## How to start:book::computer:
- Download the project from the GitHub repository.
- Navigate to the root directory of the project.
- launch the command interpreter `python ./console`.
- Utilize the provided commands to efficiently manage AirBnB objects and perform various operations with ease.
## EXAMPLES
```
$ ./console.py
(hbnb) helpDocumented commands (type help ):
========================================
EOF create destroy help quit showUndocumented commands:
======================
all update(hbnb)
(hbnb)
(hbnb) quit
$
```## Authors:pencil2:
- **Juan Ramirez** <>
- **Oscar Morales** <>