Skip to content

Instantly share code, notes, and snippets.


Vladislav Trotsenko bestwebua

Block or report user

Report or block bestwebua

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
bestwebua / active_admin.rb
Created Sep 2, 2018 — forked from llxff/active_admin.rb
Using devise + activeadmin with one User model and separate sign_in entry points
View active_admin.rb
config.authentication_method = :authenticate_admin_user!
config.current_user_method = :current_admin_user
config.logout_link_path = :destroy_user_session_path
bestwebua / howto.bash
Last active Apr 28, 2019
Rails + PostgreSQL
View howto.bash
sudo apt-get install postgresql libpq-dev cmake
sudo -u postgres createuser --interactive
sudo -u postgres createdb [your_rails_project]_development
sudo -u postgres createdb [your_rails_project]_test
sudo service postgresql restart
ps -ax | grep postg
rails s
View scraping_kata.rb
require 'nokogiri'
require 'open-uri'
class User
attr_reader :name, :clan, :honor
def initialize(name, clan, honor)
@name, @clan, @honor = name, clan, honor
You can’t perform that action at this time.