PackRat is the ultimate adventure planner designed for those who love to explore the great outdoors. Our app helps users plan and organize their trips with ease, whether it's a weekend camping trip, a day hike, or a cross-country road trip.
With PackRat, you can create and manage trips, discover new destinations, and stay informed with up-to-date weather forecasts. Our app integrates with Mapbox to provide you with accurate maps and directions to your destinations, as well as suggestions for popular outdoor activities based on the location and season of your trip.
So pack your bags, grab your friends, and get ready for your next adventure with PackRat!
- Create and manage trips: users can create new trips and manage existing ones by adding details such as dates, locations, and activities.
- Map integration: PackRat integrates with Mapbox to provide users with accurate maps and directions to their destinations.
- Activity suggestions: the app suggests popular outdoor activities based on the location and season of the trip.
- Packing list: users can create and manage packing lists for their trips to ensure they have everything they need.
- Weather forecast: PackRat provides up-to-date weather forecasts for the trip location to help users prepare accordingly.
- User authentication: the app uses user authentication to ensure privacy and data security.
PackRat is built using the following technologies:
- React Native: a JavaScript library for building user interfaces.
- Expo: a set of tools and services for building and deploying React Native applications.
- MongoDB: a document-oriented database program.
- Express.js: a web application framework for Node.js.
- Node.js: an open-source, cross-platform, back-end JavaScript runtime environment.
- Redux: a predictable state container for JavaScript apps.
- Mapbox: a location data platform for mobile and web applications.
PackRat consists of two main components: a client and a server. Follow the steps below to install and run both components.
- Clone the repository: HTTPS:
git clone https://github.com/andrew-bierman/PackRat.gitSSH:
git clone git@github.com:andrew-bierman/PackRat.git- Navigate to the
PackRatdirectory:
cd PackRat
- Set up the environment variables for the client and server.
- If you have access to the development env files, use those. Otherwise, replace the values with your own.
- See the
.env.examplefiles in theclientandserverdirectories for the necessary environment variables.
- Run the setup script from the
PackRatdirectory.
npm run setup
-
Navigate to the
PackRatdirectory if you are not already there. -
Navigate to the
clientdirectory.
cd client
- Note that for the client to run, you need to also make the following changes:
- Copy the
app.example.jsonfile and rename it toapp.json. Open the file and replace theMAPBOX_DOWNLOADS_TOKEN_FROM_ENVvalue with your own Mapbox API key. - Navigate to the ios directory. Copy the
Podfile.examplefile and rename it toPodfile. Open the file and replace theMAPBOX_DOWNLOADS_TOKEN_FROM_ENVvalue with your own Mapbox access token. - Navigate to the android directory. Copy the
gradle.properties.examplefile and rename it togradle.properties. Open the file and replace theMAPBOX_DOWNLOADS_TOKEN_FROM_ENVvalue with your own Mapbox downloads token. - See the Mapbox documentation for more information on how to obtain Mapbox API keys and access tokens.
- Copy the
- Duplicate the
.env.examplefile and rename it to.env. Open the file and replace the values with your own.- If you have access to the development env file, skip this step. Otherwise, replace the values with your own.
cp .env.example .env
- Duplicate the
app.example.jsonfile and rename it toapp.json. Open the file and replace theMAPBOX_DOWNLOADS_TOKEN_FROM_ENVvalue with your own Mapbox API key.
cp app.example.json app.json
- Navigate to the ios directory.
cd ios
- Duplicate the
Podfile.examplefile and rename it toPodfile. Open the file and replace theMAPBOX_DOWNLOADS_TOKEN_FROM_ENVvalue with your own Mapbox access token.
cp Podfile.example Podfile
- Navigate to the android directory.
cd ../android
- Duplicate the
gradle.properties.examplefile and rename it togradle.properties. Open the file and replace theMAPBOX_DOWNLOADS_TOKEN_FROM_ENVvalue with your own Mapbox downloads token.
cp gradle.properties.example gradle.properties
- Note, for the replacement steps, these replaced values should now be strings with the mapbox secret key for download token, in the following format:
"sk..."
- Navigate back to the
PackRatdirectory.
cd ../..
- Navigate to the
serverdirectory.
cd server
- Duplicate the
.env.examplefile and rename it to.env. Open the file and replace the values with your own. - If you have access to the development env file, skip this step. Otherwise, replace the values with your own.
cp .env.example .env
- Navigate back to the
PackRatdirectory.
cd ..
Recommended to open two terminal windows.
- Navigate to the
serverdirectory.
cd server
- Install dependencies for the server.
npm install
- Start the server.
npm start
- Navigate to the
clientdirectory.
cd client
- Install dependencies for the client.
npm install
- Start the Expo server.
npm start
- Here you will be able to run the app on an iOS or Android simulator (or on your own device), or on the web. See the Expo documentation for more information on how to set up your development environment.
Note that the client and server are designed to run concurrently in development mode.
PackRat can also be installed using Docker. After setting up the development environment, follow the steps below to install and run the app using Docker.
- Run the following command to start the app
docker-compose build
docker-compose up
- Navigate to
http://localhost:19000/to view the app. The server will be running onhttp://localhost:3000/. - If you encounter errors with edits to files not automatically applying, try running the following commands:
docker-compose down
docker-compose build
docker-compose up
- To stop the app, run the following command:
docker-compose down
- If you encounter issues with docker-compose, you can build the images manually by running the following commands from the root folder:
docker build -t packrat-client client/Dockerfile
docker build -t packrat-server server/Dockerfile
- To run the images, run the following commands:
docker run -p 19000:19000 packrat-client
docker run -p 3000:3000 packrat-server
Contributions to PackRat are welcome! To contribute, follow these steps:
- Fork the repository.
- Create a new branch for your changes.
- Make your changes and commit them.
- Push your changes to your fork.
- Create a pull request.
PackRat is licensed under the terms of the GNU General Public License v3.0. See LICENSE for more information.