This file contains hidden or 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
package br.inova.mobile.rest; | |
import java.io.BufferedReader; | |
import java.io.IOException; | |
import java.io.InputStreamReader; | |
import java.util.Arrays; | |
import java.util.List; | |
import org.apache.http.HttpResponse; | |
import org.apache.http.client.methods.HttpGet; |
This file contains hidden or 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
public static String getExternalSdCardPath() { | |
String path = null; | |
File sdCardFile = null; | |
List<String> sdCardPossiblePath = Arrays.asList("external_sd", "ext_sd", "external", "extSdCard"); | |
for (String sdPath : sdCardPossiblePath) { | |
File file = new File("/mnt/", sdPath); | |
if (file.isDirectory() && file.canWrite()) { |
This file contains hidden or 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
# -*- coding: utf-8 -*- | |
# Copyleft 2014 Paulo Luan <https://github.com/transparenciasjc> | |
# This program is free software: you can redistribute it and/or modify | |
# it under the terms of the GNU General Public License as published by | |
# the Free Software Foundation, either version 3 of the License, or | |
# (at your option) any later version. | |
# | |
# This program is distributed in the hope that it will be useful, | |
# but WITHOUT ANY WARRANTY; without even the implied warranty of |
This file contains hidden or 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
# ~/.bashrc: executed by bash(1) for non-login shells. | |
# see /usr/share/doc/bash/examples/startup-files (in the package bash-doc) | |
# for examples | |
# If not running interactively, don't do anything | |
case $- in | |
*i*) ;; | |
*) return;; | |
esac |
This file contains hidden or 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
squid: | |
adicionar: 'strip_query_terms off' em /etc/squid3/squid.conf | |
sudo grep -n 'strip_query_terms' /etc/squid3/squid.conf | |
sudo service squid3 restart # re-inicializa | |
sudo tail -f /var/log/squid3/access.log # monitora | |
Pegar o resultado e extrair as urls em: http://www.toolsvoid.com/extract-domains |
This file contains hidden or 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
sudo kill -9 $(sudo lsof -t -i:8080) |
This file contains hidden or 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
sudo su | |
# update system | |
apt-get update && apt-get upgrade -y | |
# download and configure Node Version Manager | |
wget -qO- https://raw.githubusercontent.com/creationix/nvm/v0.20.0/install.sh | bash && \ | |
source /root/.nvm/nvm.sh && \ | |
nvm install stable && nvm use stable && nvm alias default stable && \ | |
node -v |
This file contains hidden or 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
sed 's/main$/main universe/' -i /etc/apt/sources.list | |
apt-get update && apt-get install -y software-properties-common python-software-properties | |
add-apt-repository ppa:webupd8team/java -y | |
apt-get update | |
echo oracle-java7-installer shared/accepted-oracle-license-v1-1 select true | /usr/bin/debconf-set-selections | |
apt-get install -y oracle-java7-installer |
This file contains hidden or 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
https://gitlab.com/PauloLuan/bauru-sac-admin.git | |
[email protected]:PauloLuan/bauru-sac-admin.git | |
https://gitlab.com/PauloLuan/bauru-sac.git | |
[email protected]:PauloLuan/bauru-sac.git | |
cd C: |
This file contains hidden or 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
var module = (function () { | |
// private variables and functions | |
var foo = 'bar'; | |
// constructor | |
var module = function () { | |
configureCorsFilter(); | |
}; | |
var configureCorsFilter = function(){ |