Softwear::Lib

TODO: Write a gem description

Installation

Add this line to your application's Gemfile:

gem 'softwear-lib'

And then execute:

$ bundle

Or install it yourself as:

$ gem install softwear-lib

Usage

To use apps locally without auth_server:

$ AUTH_SERVER=false bundle exec rails s

Uses data from local users.yml.

Expected format for users.yml:


user's email:
  first_name: user's first name
  last_name: user's last name
  profile_picture: local file location
  roles:
    - role1
    - role2
    - rolen
  rights:
    - right1
    - right2
    - rightn

To include error handling in your app, add:


Include Softwear::ErrorCatcher
helper Softwear::Auth::EmailsHelper

to your application controller.

For error styling and animation add:


*= require animate/animate

.box-info-error{
  background: "your desired color here";
}

to your application.css file.

Contributing

  1. Fork it ( https://github.com/[my-github-username]/softwear-lib/fork )
  2. Create your feature branch (git checkout -b my-new-feature)
  3. Commit your changes (git commit -am 'Add some feature')
  4. Push to the branch (git push origin my-new-feature)
  5. Create a new Pull Request