Skip to content

Instantly share code, notes, and snippets.

Avatar

Danilo Domínguez Pérez danilo04

View GitHub Profile
View cfgsoot.java
PackManager.v().getPack("jtp").add(
new Transform("jtp.methodinstrumenter", new BodyTransformer() {
@Override
protected void internalTransform(Body body, String arg1,
Map<String, String> arg2) {
// this method runs for all the methods in the app under analysis
UnitGraph g = new ExceptionalUnitGraph(body);
// unit graph is a statement based control flow graph
}
View install_font.sh
#!/bin/bash
set -euo pipefail
I1FS=$'\n\t'
mkdir -p /tmp/adodefont
cd /tmp/adodefont
wget -q --show-progress -O source-code-pro.zip https://github.com/adobe-fonts/source-code-pro/archive/2.030R-ro/1.050R-it.zip
unzip -q source-code-pro.zip -d source-code-pro
mkdir -p ~/.fonts
cp -v source-code-pro/*/OTF/*.otf ~/.fonts/
fc-cache -f
View fetchupstreamgit.sh
# Add the remote, call it "upstream":
git remote add upstream https://github.com/whoever/whatever.git
# Fetch all the branches of that remote into remote-tracking branches,
# such as upstream/master:
git fetch upstream
# Make sure that you're on your master branch:
@danilo04
danilo04 / getreactive.py
Last active Aug 29, 2015
Get the reactive callbacks in Android API
View getreactive.py
#!/usr/bin/python
import os
import sys
from bs4 import BeautifulSoup
from urllib2 import urlopen
import cgi
import csv
def fromurltoname(url):
View deploysoot.sh
#!/usr/bin/env sh
#
# author: Quentin Sabah
# modified: Danilo Dominguez Perez
#
deploy_dir=$PWD
jasmin_repo=http://github.com/Sable/jasmin.git
jasmin_branch=develop
View cleanboot.sh
; restart before running this
dpkg --get-selections | \
grep 'linux-image*' | \
awk '{print $1}' | \
egrep -v "linux-image-$(uname -r)|linux-image-generic" | \
while read n
do
sudo apt-get -y remove $n
done
View issue8.java
class TestActivity extends Activity {
private mFilename;
public void onCreate(Bundle paramBundle) {
Intent localIntent = getIntent();
this.mFilename = localIntent.getData().toString();
}
protected void onDestroy() {
StringBuilder localStringBuilder;
View Referencias_BattallaLenguajes.txt
Referencias
1. https://en.wikipedia.org/wiki/Programming_paradigm
2. http://www.slideshare.net/Coverity/the-psychology-of-c-analysis-24025354
3. http://sealedabstract.com/rants/why-mobile-web-apps-are-slow/
4. http://www.youtube.com/view_play_list?p=9D558D49CA734A02
5. https://en.wikipedia.org/wiki/Type_inference
6. http://www.infoq.com/presentations/ruby-invitation
7. http://www.infoq.com/presentations/java-g1
8. https://developers.google.com/events/io/sessions/324431687
View index.php
<?php
$pageIndexToSection = array(
0 => 'inicio',
1 => 'registro',
2 => 'busqueda',
3 => 'perfil',
4 => 'perfil_publico',
5 => 'agregar_evento',
6 => 'agregar_empresa',
7 => 'buscar_certificado',
@danilo04
danilo04 / ajaxform.js
Created Jul 29, 2013
Jquery send ajax form serialize
View ajaxform.js
// this is the id of the submit button
$("#submitButtonId").click(function() {
var url = "path/to/your/script.php"; // the script where you handle the form input.
$.ajax({
type: "POST",
url: url,
data: $("#idForm").serialize(), // serializes the form's elements.
success: function(data)
You can’t perform that action at this time.