Skip to content

Instantly share code, notes, and snippets.

View 5a494d's full-sized avatar
🌴
On vacation

5a494d 5a494d

🌴
On vacation
View GitHub Profile
@5a494d
5a494d / fix-pac.sh
Created October 7, 2018 11:54
Steps to solve: Can not find "new" object method via package "Gnome2 :: Vte :: Terminal"
1 - cpan Glib::MakeHelper
2 - cpan Gnome2::Vte
3 - wget http://search.cpan.org/CPAN/authors/id/X/XA/XAOC/Gnome2-Vte-0.11.tar.gz
4 - tar xfz Gnome2-Vte-0.11.tar.gz
5 - cd Gnome2-Vte-0.11/
6 - perl Makefile.PL
7- make
8 - sudo cp -f blib/arch/auto/Gnome2/Vte/Vte.so /opt/pac/lib/ex/vte64/auto/Gnome2/Vte/
@5a494d
5a494d / template_lambda.cc
Created September 18, 2018 14:28 — forked from emaxerrno/template_lambda.cc
template_lazy_closures.cc
#include <type_traits>
#include <iostream>
// This template is called 'or_combinator'
// it takes 2 function templates 'func1' , and 'func2'
// the arguments to each type function is template<typename>
// which means any typename
// you invoke them via func1<T>::value
// but they aren't instantiated until you ask for or_combinator<>::lambda<>::value
@5a494d
5a494d / btree.cpp
Created September 18, 2018 14:13 — forked from toboqus/btree.cpp
Binary tree implementation in c++
#include <iostream>
using namespace std;
struct node{
int value;
node *left;
node *right;
};
#include <functional>
#include <string>
class EmailProcessor
{
public:
void receiveMessage (const std::string& message)
{
if ( _handler_func )
{
@5a494d
5a494d / gtkcom.sh
Created July 24, 2018 18:50
Compile and execute gtkmm file
#!/bin/bash
echo "# File name: $1"
CPPFILE=$1
# Remember to put file path to environment system
# .profile .bash_profile .bash_login
# if [ -d "$HOME/.bash" ] ; then
# PATH="$PATH:$HOME/.bash"
# fi
@5a494d
5a494d / gcompile
Last active July 19, 2018 01:59
Execute c/c++ single file with bash
#!/bin/bash
echo "# File name: $1"
CPPFILE=$1
# Remember to put file path to environment system
# .profile .bash_profile .bash_login
# if [ -d "$HOME/.bash" ] ; then
# PATH="$PATH:$HOME/.bash"
# fi

// file // app/Providers/AppServiceProvider.php // replace on function

/**
 * Register any application services.
 *
 * @return void
 */

public function register()

@5a494d
5a494d / install_monaco_font.sh
Created October 18, 2017 15:30 — forked from rogerleite/install_monaco_font.sh
Install Monaco font in Linux
#!/bin/bash
#script extraido de: http://paulocassiano.wordpress.com/2008/08/29/deixando-o-gedit-com-a-cara-do-textmate/
#tip for better "resolution" here: http://blog.siverti.com.br/2008/05/22/fonte-monaco-no-ubuntugedit/
cd /usr/share/fonts/truetype/
#TODO: put validation if folder already exists
sudo mkdir ttf-monaco
@5a494d
5a494d / create_laravel_app.sh
Last active October 12, 2017 13:51 — forked from connor11528/create_laravel_app.sh
Create a new Laravel application
#!/bin/bash
composer create-project laravel/laravel $1 --prefer-dist
cd $1
composer install
node install
touch README.md
cp .env.example .env
git init
git add -A
@5a494d
5a494d / hex-opacity-values.txt
Created October 3, 2017 14:25 — forked from frankyonnetti/CSS--hex-opacity-values.css
#css Hex Opacity Values
Hex Opacity Values
100% β€” FF
95% β€” F2
90% β€” E6
85% β€” D9
80% β€” CC
75% β€” BF
70% β€” B3
65% β€” A6