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
// Install ImageMagick | |
$ yum install ImageMagick ImageMagick-devel | |
// Install php imagick extension | |
$ yum --enablerepo=remi,remi-test install php-pecl-imagick |
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 | |
class SubdomainComponent extends Object { | |
var $__settings = array( | |
'base' => 'example.com', | |
'domains' => array(), | |
'param' => 'subdomain', | |
'redirect' => true, | |
'redirectTo' => 'http://example.com', | |
'model' => 'DomainPrefix', |
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
######################### | |
# This gist is meant to be used to install everything needed to get up and running with the Ionic Framework on Windows using Chocolatey (http://chocolatey.org) | |
# Read "How to use this Gist File" section below for instructions. | |
######################### | |
######################### | |
# NOTE : for those familiar with Chocolatey, there are a couple of custom packages used as part of the install that are not published and are waiting on maintainers to make updates to their packages. | |
######################### |
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
public class LogOutTimerUtil { | |
public interface LogOutListener { | |
void doLogout(); | |
} | |
static Timer longTimer; | |
static final int LOGOUT_TIME = 600000; // delay in milliseconds i.e. 5 min = 300000 ms or use timeout argument | |
public static synchronized void startLogoutTimer(final Context context, final LogOutListener logOutListener) { |
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
function abbreviate($string){ | |
$abbreviation = ""; | |
$string = ucwords($string); | |
$words = explode(" ", "$string"); | |
foreach($words as $word){ | |
$abbreviation .= $word[0]; | |
} | |
return $abbreviation; | |
} |
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
<IfModule mod_rewrite.c> | |
<IfModule mod_negotiation.c> | |
Options -MultiViews | |
</IfModule> | |
RewriteEngine On | |
RewriteCond %{REQUEST_FILENAME} -d [OR] | |
RewriteCond %{REQUEST_FILENAME} -f | |
RewriteRule ^ ^$1 [N] |
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
$ ffmpeg -i input.mp4 -vcodec h264 -acodec mp2 output.mp4 |
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
# create assets folder in the current project | |
$ mkdir android/app/src/main/assets | |
# create bundle script | |
$ react-native bundle --platform android --dev false --entry-file index.js --bundle-output android/app/src/main/assets/index.android.bundle --assets-dest android/app/src/main/res/ | |
# execute command to run android to create debug apk | |
$ react-native run-android | |
# Or change to android folder |
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
{ | |
"ab":{ | |
"name":"Abkhaz", | |
"nativeName":"аҧсуа" | |
}, | |
"aa":{ | |
"name":"Afar", | |
"nativeName":"Afaraf" | |
}, | |
"af":{ |
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
/*! firestoreTransforms.js | Samuel Jones 2019 | MIT License | gist.github.com/samthecodingman */ | |
/** | |
* @file A file containing common firestore idioms used with queries | |
* @author Samuel Jones 2017 (github.com/samthecodingman) | |
* @license MIT | |
* @module firestore-transforms | |
*/ | |
/** |
OlderNewer