This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"name": "Finanças Pessoais", | |
"description": "Uma API para gerenciamento de finanças pessoais", | |
"authors": [ | |
{ | |
"name": "Andre Cardoso", | |
"email": "andrecardosodev@gmail.com" | |
} | |
], | |
"require": { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php defined('BASEPATH') OR exit('No direct script access allowed'); | |
class Constructor_lib { | |
function __construct() { | |
$this->CI =& get_instance(); | |
} | |
function create_controller_files($tables = NULL, $create = FALSE) { | |
if(!$tables) $tables = $this->CI->db->list_tables(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* @todo CakePHP Permissions Array by Kevin Wentworth (Saco Design, Inc.) | |
* @todo Handles retrieving all ACL Permissions and storing them in an array. | |
* @todo Comments and bug reports welcome at kevin at sacode sign dot com | |
* | |
* @licensed Licensed under UYOR (Use at Your Own Risk) | |
* @link http://www.mainelydesign.com/blog/view/getting-all-acl-permissions-in-one-lookup-cakephp-1-3#null | |
*/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$acao = $_POST['acao']; | |
$dispositivos = "dispositivos.txt"; | |
if ($acao == "registrar") { | |
$fp = fopen($dispositivos, "a+") or die("Erro ao abrir arquivo!"); | |
$registrationId = $_POST['regId'] ."\n"; | |
fwrite($fp, $registrationId) or die("Erro ao escrever no arquivo!"); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
echo "deb http://http.debian.net/debian/ jessie main contrib" | sudo tee -a /etc/apt/sources.list.d/contrib.list | |
sudo apt-get update && sudo apt-get install java-package libgl1-mesa-glx libxtst6 libxxf86vm1 | |
wget --no-check-certificate --no-cookies --header "Cookie: oraclelicense=accept-securebackup-cookie" http://download.oracle.com/otn-pub/java/jdk/8u45-b14/jdk-8u45-linux-x64.tar.gz | |
make-jpkg jdk-8u45-linux-x64.tar.gz | |
sudo dpkg -i oracle-java8-jdk_8u45_amd64.deb |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
app.filter('sprintf', function() { | |
function parse(str) { | |
var args = [].slice.call(arguments, 1), | |
i = 0; | |
return str.replace(/%s/g, function() { | |
return args[i++]; | |
}); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import java.io.IOException; | |
import java.io.InputStream; | |
import java.net.MalformedURLException; | |
import org.apache.http.HttpResponse; | |
import org.apache.http.client.methods.HttpGet; | |
import org.apache.http.impl.client.DefaultHttpClient; | |
import android.content.Context; | |
import android.graphics.Canvas; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"AWSTemplateFormatVersion": "2010-09-09", | |
"Description": "CloudFormation Sample Template for Node.js application. **WARNING** This template creates an Amazon EC2 instance. You will be billed for the AWS resources used if you create a stack from this template.", | |
"Parameters": { | |
"InstanceType": { | |
"Description": "EC2 instance type", | |
"Type": "String", | |
"Default": "t1.micro", |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import axios from 'axios'; | |
// You can use any cookie library or whatever | |
// library to access your client storage. | |
import cookie from 'cookie-machine'; | |
axios.interceptors.request.use(function(config) { | |
const token = cookie.get(__TOKEN_KEY__); | |
if ( token != null ) { | |
config.headers.Authorization = `Bearer ${token}`; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
SHORTCUT="[Desktop Entry] | |
Name=Sublime Text 3 | |
Comment=Edit text files | |
Exec=/opt/sublime_text_3/sublime_text | |
Icon=/opt/sublime_text_3/Icon/128x128/sublime-text.png | |
Terminal=false | |
Type=Application | |
Encoding=UTF-8 | |
Categories=Utility;TextEditor;" |
OlderNewer