Skip to content

Instantly share code, notes, and snippets.

View amieiro's full-sized avatar

Jesús Amieiro Becerra amieiro

View GitHub Profile
@amieiro
amieiro / iterm2-solarized.md
Created December 25, 2023 12:53 — forked from kevin-smets/iterm2-solarized.md
iTerm2 + Oh My Zsh + Solarized color scheme + Source Code Pro Powerline + Font Awesome + [Powerlevel10k] - (macOS)

Default

Default

Powerlevel10k

Powerlevel10k

@amieiro
amieiro / gist:7bbf82e574a756dad5b0819df3ae9438
Created September 7, 2022 08:30
GlotPress. Alphabet for each locale. File locales.php in the locale folder.
<?php
if ( ! class_exists( 'GP_Locale' ) ) :
class GP_Locale {
public $english_name;
public $native_name;
public $text_direction = 'ltr';
public $lang_code_iso_639_1 = null;
public $lang_code_iso_639_2 = null;
public $lang_code_iso_639_3 = null;
@amieiro
amieiro / install-glotpress-phpunit.sh
Created September 16, 2021 16:56
Set the GlotPress PHPUnit environment
#!/usr/bin/env bash
# Constants. Update it as you need
GLOTPRESS_BASE_DIR=/Users/amieiro/code/wordpress/wp/wp-content/plugins/GlotPress-WP
WP_TEST_INSTALL_BASE_DIR=/Users/amieiro/code/wordpress/tests
DB_NAME=wp_test
DB_USER=wp_test
DB_PASSWORD=password
DB_HOST=localhost
WP_VERSION=latest
@amieiro
amieiro / wp-create.sh
Last active August 29, 2022 21:54
WordPress installation script
#!/usr/bin/env bash
# wp-create.sh
# This script creates:
# 1. A user in the system with his own directory
# 2. Create the database, the user and grant access to this user to this database
# 3. Download WordPress, create the config file and install WordPress
# This script doesn't configure the webserver neither the PHP-FPM
@amieiro
amieiro / SQL para insertar las provincias españolas
Created November 30, 2016 11:48
SQL para insertar las provincias españolas
INSERT INTO `mi_base_de_datos`.`provincias` (`id`, `nombre`, `created_at`, `updated_at`) VALUES (NULL, 'Araba/Álava', CURRENT_TIMESTAMP(), CURRENT_TIMESTAMP());
INSERT INTO `mi_base_de_datos`.`provincias` (`id`, `nombre`, `created_at`, `updated_at`) VALUES (NULL, 'Albacete', CURRENT_TIMESTAMP(), CURRENT_TIMESTAMP());
INSERT INTO `mi_base_de_datos`.`provincias` (`id`, `nombre`, `created_at`, `updated_at`) VALUES (NULL, 'Alicante/Alacant', CURRENT_TIMESTAMP(), CURRENT_TIMESTAMP());
INSERT INTO `mi_base_de_datos`.`provincias` (`id`, `nombre`, `created_at`, `updated_at`) VALUES (NULL, 'Almería', CURRENT_TIMESTAMP(), CURRENT_TIMESTAMP());
INSERT INTO `mi_base_de_datos`.`provincias` (`id`, `nombre`, `created_at`, `updated_at`) VALUES (NULL, 'Ávila', CURRENT_TIMESTAMP(), CURRENT_TIMESTAMP());
INSERT INTO `mi_base_de_datos`.`provincias` (`id`, `nombre`, `created_at`, `updated_at`) VALUES (NULL, 'Badajoz', CURRENT_TIMESTAMP(), CURRENT_TIMESTAMP());
INSERT INTO `mi_base_de_datos`.`provincias` (`id`, `nombre`, `created_
<?php
/*
(2014) Main source -> http://lancenewman.me/posting-a-photo-to-instagram-without-a-phone/
I just managed to sniff Instagram traffic and fixed the code
-- Have fun - batuhan.org - Batuhan Katırcı
--- for your questions, comment @ http://batuhan.org/instagram-photo-upload-with-php/