Skip to content

Instantly share code, notes, and snippets.

View rogeriopradoj's full-sized avatar
😀

Rogerio Prado de Jesus rogeriopradoj

😀
View GitHub Profile
@rogeriopradoj
rogeriopradoj / gitBash_windows.md
Created July 14, 2018 18:16 — forked from evanwill/gitBash_windows.md
how to add more utilities to git bash for windows, wget, make

How to add more to Git Bash on Windows

Git for Windows comes bundled with the "Git Bash" terminal which is incredibly handy for unix-like commands on a windows machine. It is missing a few standard linux utilities, but it is easy to add ones that have a windows binary available.

The basic idea is that C:\Program Files\Git\mingw64\ is your / directory according to Git Bash (note: depending on how you installed it, the directory might be different. from the start menu, right click on the Git Bash icon and open file location. It might be something like C:\Users\name\AppData\Local\Programs\Git, the mingw64 in this directory is your root. Find it by using pwd -W). If you go to that directory, you will find the typical linux root folder structure (bin, etc, lib and so on).

If you are missing a utility, such as wget, track down a binary for windows and copy the files to the corresponding directories. Sometimes the windows binary have funny prefixes, so

@rogeriopradoj
rogeriopradoj / intro.md
Created June 28, 2018 14:50 — forked from derhuerst/intro.md
Installing Git on Linux, Mac OS X and Windows
@rogeriopradoj
rogeriopradoj / mbp2011-disable-amd-gpu.md
Created June 2, 2018 22:12 — forked from blackgate/mbp2011-disable-amd-gpu.md
Macbook Pro 2011 - Disable AMD GPU
@rogeriopradoj
rogeriopradoj / README.md
Created December 21, 2017 09:46 — forked from lpar/README.md
How to make Hugo (0.20+) generate an Atom feed instead of RSS

The Hugo static site generator sadly still uses the obsolete and badly standardized RSS format.

Here's how to set it up to generate an Atom feed instead. Pretty much all feed readers which understand RSS also understand Atom, except iTunes, and Atom is a better format.

  1. Define an appropriate media type and corresponding output format in config.toml:
@rogeriopradoj
rogeriopradoj / web.config
Created November 22, 2017 21:04 — forked from gon250/web.config
Enable cors domain in the web.config
<httpProtocol>
<customHeaders>
<add name="Access-Control-Allow-Origin" value="*" />
<add name="Access-Control-Allow-Headers" value="Content-Type" />
<add name="Access-Control-Allow-Methods" value="GET, POST, PUT, DELETE, OPTIONS" />
</customHeaders>
</httpProtocol>
@rogeriopradoj
rogeriopradoj / CodeIgniter_PDOSQLiteMySQL.php
Created November 20, 2017 18:20 — forked from yuigoto/CodeIgniter_PDOSQLiteMySQL.php
How to setup PDO and SQLite for CodeIgniter (for SQLite and MySQL). This is the `database.php` file in `the application/config` folder
<?php
defined('BASEPATH') OR exit('No direct script access allowed');
$active_group = 'default';
$query_builder = TRUE;
// FOR SQLITE
$db['default'] = array(
'dsn' => 'sqlite:[path-to-database-file]',
'hostname' => 'localhost',
@rogeriopradoj
rogeriopradoj / auto-deploy.md
Created October 21, 2017 12:05 — forked from domenic/0-github-actions.md
Auto-deploying built products to gh-pages with Travis

Auto-deploying built products to gh-pages with Travis

This is a set up for projects which want to check in only their source files, but have their gh-pages branch automatically updated with some compiled output every time they push.

Create a compile script

You want a script that does a local compile to e.g. an out/ directory. Let's call this compile.sh for our purposes, but for your project it might be npm build or gulp make-docs or anything similar.

The out/ directory should contain everything you want deployed to gh-pages. That almost always includes an index.html.

@rogeriopradoj
rogeriopradoj / cntlm_npm.md
Created August 22, 2017 20:11 — forked from triskell/cntlm_npm.md
[Windows 7] CNTLM and NPM behind NTLM proxy

CNTLM and NPM behind NTLM proxy on Widows 7

CNTLM

  • Install CNTLM in a folder where you have full rights to run it as administrator.

  • Open cntlm.ini and fill it :

Username    YOUR_USERNAME
Domain YOUR_DOMAIN
@rogeriopradoj
rogeriopradoj / dockersp.md
Created April 30, 2017 11:53 — forked from fike/dockersp.md
Guia do palestrante do Docker SP

Olá!

Nós, Docker SP, estamos contentes em saber do seu interesse em dar uma palestra no Meetup Docker São Paulo.

Aqui está uma sugestão de como preparar uma apresentação na perspectiva da organização:

  • Quando for uma apresentação do tipo mão na massa, interessante demostrar como as funcionalidades do Docker e ecossistema funcionam. Uma boa regra da apresentação ter 50% de demostração e 50% de apresentação, discussão, etc.

  • A palestra estará compartilhando conhecimento para o grupo, nós gostaríamos de educar nossos membros para aprender mais sobre Docker a cada evento. Mais discussões e compartilhamento de conhecimento sobre ferramentas do ecossistema de containers, arquitetura moderna de aplicações, prática e cultura de engenharia também é bem-vinda.  

@rogeriopradoj
rogeriopradoj / phpstorm-vs-sublimetext-shortcuts.md
Created April 25, 2017 03:49 — forked from silasrm/phpstorm-vs-sublimetext-shortcuts.md
Teclas de atalhos do PHPStorm com funções semelhantes ao Sublime Text, e outras interessantes.

#Teclas de atalhos do PHPStorm com funções semelhantes ao Sublime Text, e outras interessantes.

Sublime Text PHPStorm Função
CMD+P CMD+Shift+O Busca por arquivos no projeto
CMD+R CMD+F12 (1) Lista os métodos da classe e outros símbolos
CMD+F CMD+F Busca no arquivo
CMD+Option+F CMD+R Busca e troca os valores no arquivo
CMD+Shift+F CMD+Shift+F Busca, busca e troca e outros em um determinado caminho com várias regras.
CMD+D (2) Option+Up (2) Seleciona palavra