Skip to content

Airbnb clone built using Ruby, Sinatra and PostgreSQL

Notifications You must be signed in to change notification settings

jillwones/makers-bnb

Repository files navigation

MakersBnB

About this project

MakersBnB is a web-app similar to Airbnb and was built using Ruby, Sinatra and PostgreSQL. It allows users to: sign up and log in; view, create and book property listings; manage booking requests; and send messages between hosts and customers. In addition to these features, Twilio text notifications have been set up to let customers know if their booking request has been accepted/rejected, and notify hosts if a customer has requested to stay at their property (the code for this feature has been temporarily commented out due to limitations in Twilio's free plan). This was a group project completed during week 5 of the Makers bootcamp.

Learnings from this project

Through creating this app in a group environment, I improved my ability to:

  • Work and communicate effectively within a software development team
  • Break down projects into tasks and assign them to pairs
  • Use agile ceremonies to organise work into sprints and improve processes
  • Use a developer workflow to plan, implement and peer-review features
  • Build fullstack web applications using Ruby and the Sinatra framework
  • Create SQL databases and implement routes that interact with and manipulate data in these databases
  • Implement user authentication using bcrypt
  • Set up text notifications with Twilio
  • Carry out unit and integrations tests with RSpec
  • Use Embedded Ruby (ERB) to dynamically edit HTML view pages
  • Style websites with CSS

Installation

How to install the code

  • Clone this repository to your local machine
  • Navigate into the project directory: cd makers-bnb
  • Install the necessary dependencies: bundle install

How to set up the databases

  • Install PostgreSQL database (if necessary)
  • Create a development database: createdb makers_bnb_development
  • Create a test database: createdb makers_bnb_test
  • Set up the tables in the development database: psql -h 127.0.0.1 makersbnb < tables.sql
  • Set up the seeds in the development database: psql -h 127.0.0.1 makersbnb < ./spec/seeds.sql
  • Set up the tables in the test database: psql -h 127.0.0.1 makersbnb_test < tables.sql
  • Set up the seeds in the test database: psql -h 127.0.0.1 makers_bnb_test < ./spec/seeds.sql

How to run the code

  • Navigate into the project directory: cd makers-bnb
  • Run rackup: rackup
  • Open your web browser and go to http://localhost:9292/
  • You can then explore the website. Please note that you will need to sign up and log in to gain full access.

How to run the tests

  • Navigate into the project directory: cd makers-bnb
  • Run the tests: rspec
  • Please note that three tests have been temporarily deactivated as every time they are run, Twilio will generate text messages for each of them. If they are activated, they will all pass (as can be seen in the screenshot at the bottom of this readme).

Screenshots

Login page

screenshot of the login page

Signup page

screenshot of the signup page

Logged in home page

screenshot of the home page after logging in

View all listings

screenshot of view all listings page

View an individual listing

screenshot of an individual listing

Create a listing

screenshot of creating a listing

View my listings

screenshot of my listings

Requests for me

screenshot of requests for me

Requests made by me

screenshot of requests made by me

Messaging between a host and customer

screenshot 1 of messaging between a host and a customer screenshot 2 of messaging between a host and a customer

All 46 tests passing

screenshot of tests

About

Airbnb clone built using Ruby, Sinatra and PostgreSQL

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published