This is a membership application app written by members of Double Union, a feminist hacker/makerspace for women in San Francisco.
This application has a lot of cool features, including:
- Prospective members can apply for membership
- Current members can vote and comment on applications
- Current members can see a directory of members
- Current members can pay dues via Stripe
- Membership coordinators can manage member status
The application supports three levels of membership: members, key members, and voting members, where any member can see and comment on an application, but only voting members can vote. Membership coordinators can set whether the app is accepting applications, accept or reject individual applications, manage membership levels, and review dues status.
It is currently very Double Union specific, but we are in the process of extracting the Double Union things out of it, so that other feminist hacker/makerspaces can use it, too! We are open sourcing the app now so that we can work with other hacker/makerspaces on that process. This app supports an application process that helps us maintain a safe space for our members, and we want this app to help other groups that have the same goal.
If you're interested in using Arooo for your org and want to get in touch, make an issue and we can chat. 💃
We use GitHub issues for feature development and bug tracking, so take a look for things that you can work on, and comment with any questions you have about half-baked issues.
If you are new to Rails, follow the RailsBridge Installfest instructions for getting your environment set up.
-
Standard Rails app setup
cp config/database.example.yml config/database.yml
- Optional: edit database.yml if you want to change advanced things
rake db:create
rake db:migrate
rake db:test:prepare
-
Go here and set up an application: http://github.com/settings/applications/new
- Application name: Whatever you want
- Homepage URL: http://localhost:3000
- Authorization callback URL: http://localhost:3000/auth/github/callback
-
cp config/application.example.yml config/application.yml
-
Edit config/application.yml
- set
GITHUB_CLIENT_KEY
andGITHUB_CLIENT_SECRET
to the Client ID and Client Secret from your Github application - don't forget to restart your Rails server so it can see your shiny new GitHub key & secret
- set
-
Use
rake secret
to generate a secret token, then set that as an environment variable.
Write specs! Yay! Especially for anything involving authorization walls.
Run rake db:test:prepare
after you pull or make any changes to the app, generally
Make sure bundle exec rspec
passes before pushing your changes.
Development: $ bundle exec rails console
Production: $ heroku run rails console
To add a bunch of users to your dev database, you can use bundle exec rake populate:users
. They will have random states.
The current User state machine can be found in app/models/user.rb
, but since
it probably won't change much and it's the main moving piece of the
application, here's a quick summary.
Valid states:
visitor
: default state, no admin access, no application accessapplicant
: not yet a member, no admin access, can only view/edit/save/submit their applicationmember
: access to member admin section, cannot votekey_member
: access to member admin section, cannot vote, has keys to the spacevoting_member
: access to member admin section, can vote, has keys to the space
Manually changing a user's state from the rails console:
> user = User.find_by_username('someusername')
> user.state # => "visitor"
> user.make_applicant! # => true
> user.make_member! # => true
> user.make_key_member! # => true
> user.make_voting_member! # => true
> user.make_applicant! # => raises invalid state transition error
> user.update_attribute(:state, 'applicant') # bypasses normal checks & succeeds
If you are new to GitHub, you can use this guide for help making a pull request.
- Fork it
- Get it running
- Create your feature branch
git checkout -b my-new-feature
- Write your code and specs
- Commit your changes
git commit -am 'Add some feature'
- Push to the branch
git push origin my-new-feature
- Create a new Pull Request, linking to the GitHub issue url the Pull Request is fixing in the description
- If you find bugs, have feature requests or questions, please file an issue.
This section only pertains if you have doubleunion/doubleunion write/push access.
- Read through the GitHub issue that the Pull Request is fixing
- Code review the Pull Request, commenting on any potential issues, improvements, or telling the person how awesome their code is
- After the Pull Request is reviewed & fixed (if necessary) and the Travis CI build is passing, merge the Pull Request into
master
- Delete the branch, and close the relevant issue if not referenced in the Pull Request already
- Deploy! (see below)
This section only pertains if you have Heroku & Deployment access.
- Add Heroku remotes to your
.git/config
[remote "production"]
url = git@heroku.com:doubleunion.git
fetch = +refs/heads/*:refs/remotes/heroku/*
[remote "staging"]
url = git@heroku.com:doubleunion-staging.git
fetch = +refs/heads/*:refs/remotes/heroku/*
- Pull down the latest code from
master
git checkout master
git pull --rebase origin master
- If Travis CI tests are passing, push to the
staging
environment
git checkout master
git pull --rebase origin master
git push staging master
- If needed, perform rake tasks or set ENV variable settings on
staging
- Test staging!
username: doubleunion
password: meritocracyisajoke
- After confirming that the code works on
staging
, push it toproduction
!
git checkout master
git pull --rebase origin master
git push production master
- If needed, perform rake tasks or set ENV variable settings on
production
This app is named after a famous Virginia Woolf essay. You can learn more about it on Wikipedia!
Also, here is a puppy that is saying "arooo":
Copyright (C) 2014 Double Union
This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
See the LICENSE.txt file for the full license.