Skip to content

Instantly share code, notes, and snippets.

View dancr13's full-sized avatar
😎

Daniel dancr13

😎
View GitHub Profile
@dancr13
dancr13 / signalign
Last active September 21, 2015 01:10 — forked from mirkonasato/signalign
Sign and align an Android APK
#!/bin/sh
#
# Automates signing and aligning Android APKs as per
# http://developer.android.com/tools/publishing/app-signing.html#signing-manually
#
# USAGE: signalign platforms/android/build/outputs/apk/android-release-unsigned.apk
#
set -e
# configure the next two properties for your own certificate
@dancr13
dancr13 / data.json
Last active December 16, 2015 16:05
{"compute_objectives_count":7063,"compute_objectives_last30_count":10,"compute_objectives_num_servers_sum":147757,"compute_objectives_cores_sum":57952.0,"compute_objectives_ram_sum":186426.993375001,"compute_objectives_storage_sum":1434108,"compute_objectives_num_servers_distribution":[1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,32,33,34,35,36,38,40,42,43,44,46,47,48,50,51,52,56,59,60,61,62,64,65,66,67,72,76,78,80,83,84,86,89,90,91,93,96,100,101,110,115,116,120,126,128,131,134,135,140,148,150,151,154,158,162,176,178,181,184,185,192,202,211,216,240,280,288,296,297,300,307,360,366,376,378,384,396,400,464,481,500,525,538,588,592,600,624,640,651,665,691,712,769,800,812,832,862,922,960,1120,1149,1159,1229,1247,1312,1349,1428,1502,1540,1600,1613,1690,1763,1813,2127,2500,3000,3200,3600,4754,5166,6566,null],"objectives_count":1214,"objectives_last30_count":38,"compute_contracts_count":2881,"compute_contracts_last30_count":30,"compute_contracts_num_servers_sum":106191,"compute_cont
{
"servers_by_os": {
"comments": [{"username":"ramiro", "comment":"this is a test"}]
},
"top_profiles": {
"comments": [{"username":"daniel", "comment":"comment "},
{"username":"juan", "comment":"this is a test by Juan"}
]
},
<?php
class RemoteConnect
{
public function connectToServer($serverName=null)
{
if($serverName==null){
throw new Exception("That's not a server name! ");
}
$fp = fsockopen($serverName,80);
return ($fp) ? true : false;
<?php
require_once('RemoteConnect.php');
class RemoteConnectTest extends PHPUnit_Framework_TestCase
{
public function setUp(){ }
public function tearDown(){ }
public function testConnectionIsValid()
And this is our simple yml:
machine:
php:
version: 5.5.11
test:
override:
- phpunit ./RemoteConnectTest.php
<html>
<header>
<link rel="stylesheet" href="https://cssgram-cssgram.netdna-ssl.com/cssgram.min.css">
<title>CSS GRAM</title>
<style class="css/text">
figure {
max-width: 550px;
max-height: 550px;
}
/* Small devices (tablets, 768px and up) */
@media (min-width: 768px) {
}
/* Medium devices (desktops, 992px and up) */
@media (min-width: 992px) {
}
@dancr13
dancr13 / Diputados.php
Created July 18, 2017 13:20 — forked from chongkan/Diputados.php
Diputadas y Diputados de Costa Rica en Formato JSON
<?php
include('simple_html_dom.php');
$diputadosCostaRica = new DiputadosCostaRica();
$diputadosCostaRica->index();
@dancr13
dancr13 / importer.php
Created August 24, 2017 04:52
Prueba Importador Json
<?php
/**
* WordPress Cron Implementation for hosts, which do not offer CRON or for which
* the user has not set up a CRON job pointing to this file.
*
* The HTTP request to this file will not slow down the visitor who happens to
* visit when the cron job is needed to run.
*
* @package WordPress
*/