- nix with flakes enabled
- docker
- Clone this repo
- Copy the env file
cp .env.local.sample .env.local
- Run
nix develop
inside the directory. This will create an environment that has all the dependencies installed locally. If you don't have flakes enabled, there's a backwards-compatiblenix-shell
as well. - Inside the nix shell, run
docker-compose up -d
- Setup everything, run
mix bb.init
You'll want to be inside the nix-shell
when working on this project. Make sure postgres is running with docker-compose up -d
As you develop, when you've downloaded new code, you can run mix setup
to update the dependencies and run any migrations.
To start the server & console run:
scripts/server
Note: if you want the Elixir language server to be accessible to your editor, you will have to launch your editor from within the nix-shell
, or do some direnv or lorri magic.
You can run the entire test suite with
scripts/test
If you wish to run a specific test you can provide a file and optionally a line number
scripts/test path/to/test.exs:LINENUMBER
Format code with
scripts/format
There is probably a way to set up your editor to run scripts/format
on save. This article may help in a VS Code context.
You can also add mix format --check-formatted
to a Git pre-commit hook to have git automatically error on git commit
if formatting needs to be applied.
Note: similar to having the Elixir language server available in your editor you may need to launch your editor from within nix-shell
or otherwise make sure your editor can find/run scripts/format
.
niv is used to ensure everyone is using the same version of nixpkgs. To update the nixpkgs version run:
nix-shell -p niv
niv update
You can then commit the changes.
Force push to the staging branch in order to deploy to staging
scripts/deploy_staging
Pushes to the main
branch (including merged PRs) automatically trigger a production deploy. Please be aware of this when pushing small changes without a PR.
- Google Drive API
- Google Maps API
- Google Storage API
- LeafletJS
- Mailchimp API
- Mapbox Tiles
- Slack API
- Tailwind
- TailwindUI - paid library of Tailwind components. Licensed to @mveytsman.
- Twilio
This project's history has been squashed as part of open-sourcing, so not all contributions are reflected in the Git history.
Please see CONTRIBUTORS.md for the list of contributors.
Copyright 2021 The Bike Brigade Inc.
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.