Skip to content

Instantly share code, notes, and snippets.

View abner's full-sized avatar

Ábner Silva de Oliveira abner

View GitHub Profile
@abner
abner / index.html
Last active April 14, 2017 13:17 — forked from anonymous/index.html
CycleJS with HttpDriver// source http://jsbin.com/vomumoj
<script src="http://cdn.jsdelivr.net/chartist.js/latest/chartist.min.js"></script>
<link href="http://cdn.jsdelivr.net/chartist.js/latest/chartist.min.css" rel="stylesheet" type="text/css" />
<!DOCTYPE html>
<html>
<head>
<script src="https://cdnjs.cloudflare.com/ajax/libs/rxjs/4.0.6/rx.all.js"></script>
<script src="https://rawgit.com/cyclejs/cycle-core/v6.0.0/dist/cycle.js"></script>
<script src="https://rawgit.com/cyclejs/cycle-dom/v9.0.1/dist/cycle-dom.js"></script>
<script src="https://rawgit.com/cyclejs/cycle-http-driver/v7.0.0/dist/cycle-http-driver.min.js"></script>
<meta charset="utf-8">
@abner
abner / PostgresJSONB-operations.md
Created January 18, 2017 09:37
Postgres JSONB Operations
-- Table: public.document

-- DROP TABLE public.document;

CREATE TABLE public.document
(
@abner
abner / app.ts
Created January 11, 2017 14:10 — forked from lricoy/app.ts
Simple Angular2/Ionic2 auth
//TODO: Validar os operadores necessários para diminuir o tamanho
import 'rxjs/Rx';
import {App, Platform} from 'ionic-angular';
import {StatusBar} from 'ionic-native';
import {LoginPage} from './pages/login/login';
import {HttpClient} from "./common/providers/http";
@abner
abner / introrx.md
Created December 17, 2016 21:50 — forked from staltz/introrx.md
The introduction to Reactive Programming you've been missing
@abner
abner / rxjs_operators_by_example.md
Created December 17, 2016 13:19 — forked from btroncone/rxjs_operators_by_example.md
RxJS 5 Operators By Example
@abner
abner / selinux-cheatsheet.md
Created November 23, 2016 19:19 — forked from Hellyna/selinux-cheatsheet.md
SELinux Cheatsheet

SELinux Cheatsheet

Change context: chcon

chcon -u 'something_u' -r 'something_r' -t 'something_t' file
chcon -R -u 'something_u' -r 'something_r' -t 'something_t' dir
chcon --reference 'file_with_target_context' file
chcon -R --reference 'file_with_target_context' dir

Restore context: restorecon

@abner
abner / runtimeMethods.ts
Created May 23, 2016 20:58
Typescript - Runtime Methods
interface MusicKeyboard {
playC(): string;
}
function addMusicKeyboardMethods(object: Object): MusicKeyboard {
Object.defineProperties(object, {
"playC": function() {
return "Playing C on Keyboard";
}
@abner
abner / EMACS24.5-Ubuntu14.md
Created February 16, 2016 22:11
EMACS 24.5 - Ubuntu 14

Install

wget ftp://ftp.gnu.org/gnu/emacs/emacs-24.5.tar.gz
tar -xzvf emacs-24.5.tar.gz

#  sudo apt-get build-dep emacs24
sudo apt-get install build-essential
sudo apt-get install libXpm-dev
sudo apt-get install libgif-dev
@abner
abner / index.ts
Created February 12, 2016 22:15 — forked from davideast/index.ts
Simple Angular 2 Forms with Firebase
import {bootstrap, Component, Decorator, View, If, For, EventEmitter} from 'angular2/angular2';
import {FormBuilder, Validators, FormDirectives, ControlGroup} from 'angular2/forms';
@Component({
selector: 'app',
injectables: [FormBuilder]
})
@View({
template: `
<div class="container" [control-group]="myForm">
@abner
abner / app myDirective.js
Last active December 7, 2015 15:29 — forked from vucalur/app myDirective.js
Yeoman - AngularJS : karma configuration for directives testing
// file: app/scripts/directives/myDirective.js
angular.module('someApp.directive').directive('myDirective', function () {
return {
templateUrl: 'templates/myDirective.html', // HERE
....
}
});