https://github.com/jhu-library-applications/hummingbird
A Rails application for managing the Database A-Z list.
https://github.com/jhu-library-applications/hummingbird
Last synced: 7 months ago
JSON representation
A Rails application for managing the Database A-Z list.
- Host: GitHub
- URL: https://github.com/jhu-library-applications/hummingbird
- Owner: jhu-library-applications
- License: mit
- Created: 2022-04-28T17:23:19.000Z (about 3 years ago)
- Default Branch: main
- Last Pushed: 2023-01-19T23:08:22.000Z (over 2 years ago)
- Last Synced: 2023-03-05T03:23:54.497Z (over 2 years ago)
- Language: Ruby
- Homepage:
- Size: 636 KB
- Stars: 0
- Watchers: 3
- Forks: 0
- Open Issues: 6
-
Metadata Files:
- Readme: README.md
- License: LICENSE.md
- Code of conduct: CODE_OF_CONDUCT.md
Awesome Lists containing this project
README
# hummingbird
 [](https://codecov.io/gh/jhu-library-applications/hummingbird)A Rails application for managing the Database A-Z list.
# Instructions for running the application
1. Install Docker Desktop if you are using a Mac or PC.
2. Run the following commands to install the dependencies and create the initial database.## Run with the Makefile
To run the server with the Makefile, run the following command:
```
make up
```To run the specs, run the following command:
```
make test
```## Run using docker-compose directly
```
docker-compose up --build
docker-compose run --rm hummingbird bundle
docker-compose run --rm hummingbird bundle exec rails db:create
docker-compose run --rm hummingbird bundle exec rails db:migrate
docker-compose up
```# Running the specs
```
docker-compose run --rm hummingbird bundle exec spec
```# Resetting Database on Local Instance
If you are testing on a local instance and create records in the database, you will want to delete them before testing a newer version that changes the DB schema. Your old records may be in violation of rules in the new version of the DB.Delete existing local DB
```
docker-compose run hummingbird rake db:drop
```Setting up database again
```
docker-compose run --rm hummingbird bundle exec rails db:migrate
```Then run the "make" command as above.
# Seeding the databaseTo seed the database with the data located in `test_data`, run the following command:
`docker-compose run --rm hummingbird bundle exec rails db:seed`
This command will destory existing database entries and seed the database with the data in `test_data`.