Skip to content

Instantly share code, notes, and snippets.

View galaydaroman's full-sized avatar

galaydaroman galaydaroman

View GitHub Profile
@galaydaroman
galaydaroman / foo.cpp
Created May 14, 2020 00:02
Valera lab
#include <iostream>
using namespace std;
int main()
{
// Data
int **matrix, size, counter = 0, max;
int x, y;
bool up = true;
@galaydaroman
galaydaroman / multiple_ssh_setting.md
Created September 18, 2019 15:33 — forked from jexchan/multiple_ssh_setting.md
Multiple SSH keys for different github accounts

Multiple SSH Keys settings for different github account

create different public key

create different ssh key according the article Mac Set-Up Git

$ ssh-keygen -t rsa -C "[email protected]"

Some devs are experiencing problem with pow, once we connected to enova VPN (e.g. WFH). Usually to connect to enova VPN we use Cisco AnyConnect Secure Mobility Client tool. And this tool is causing to stop pow working. Actual problem connected with system firewall. Once Cisco AnyConnect tool make a connection, it also add some additional rulesets to the system firewall. So, all firewall setting are living in file /etc/pf.conf. And it original content looks like this:

#
# Default PF configuration file.
#
# This file contains the main ruleset, which gets automatically loaded
# engines file strucuture at CD
# each stuff should be namespaced with, for example, `my_engine`
- engines
+ my_engine
+ app
+ assets
+ images
+ my_engine
image.png
+ javascripts
@galaydaroman
galaydaroman / matches.rb
Last active February 21, 2017 23:35
Solution to correct the equations with matches
module Matches
MATCH_BITS = {
' ' => '',
'0' => '123567',
'1' => '36',
'2' => '13457',
'3' => '13467',
'4' => '2346',
'5' => '12467',
'6' => '124567',
@galaydaroman
galaydaroman / chruby.rb
Last active August 2, 2017 01:43
chruby compatibility with RVM (injection in /usr/local/share/chruby/chruby.sh) and windows chruby
# require 'pry'
# binding.pry
linked_folder = 'C:\\Rails\\RubyCurrent'
rubies = {
'2.1' => 'C:\\Rails\\Ruby2.1.0',
'2.2' => 'C:\\Rails\\Ruby2.2.0'
}
current_version = RUBY_VERSION[/\d.\d/]
[
//
// TABS (REGULAR)
//
// Tab set
{
"class": "tabset_control",
"layer0.texture": "",
require 'active_support'
require 'active_model'
require 'pry'
require 'awesome_print'
AwesomePrint.pry!
class Ages
extend ActiveModel::Naming
include ActiveModel::Validations
@galaydaroman
galaydaroman / ssh_forward_command.md
Created May 16, 2016 21:39
Postgres port forwarding on AWS via SSH

HOW TO CONNECT TO REMOTE DATABASE VIA LOCAL RAILS C

ssh -vNgL 5433:postgres.intenal-remote.host:5432 <host>

on database.yml

development:
@galaydaroman
galaydaroman / youtube_adv.user.js
Last active January 29, 2016 21:20
Userscripts
// ==UserScript==
// @name Remove YouTube advertising
// @version 0.1
// @description try to take over the world!
// @author You
// @include https://*.youtube.com/*
// @include https://youtube.com/*
// @include http://*.youtube.com/*
// @include http://youtube.com/*
// @grant unsafeWindow