Skip to content

Instantly share code, notes, and snippets.

seanf / process.kt
Created Aug 23, 2017
Execute process from Kotlin
View process.kt
import java.lang.ProcessBuilder.Redirect
import java.util.concurrent.TimeUnit
fun String.runCommand(workingDir: File? = null) {
val process = ProcessBuilder(*split(" ").toTypedArray())
if (!process.waitFor(10, TimeUnit.SECONDS)) {
fernandohu / Reading configuration files before application startup in Angular2 final
Last active Jun 18, 2020
Reading configuration files before application startup in Angular2 final release
View Reading configuration files before application startup in Angular2 final

Reading data before application startup in Angular 2

In this demonstration I will show you how to read data in Angular2 final release before application startup. You can use it to read configuration files like you do in other languages like Java, Python, Ruby, Php.

This is how the demonstration will load data:

a) It will read an env file named 'env.json'. This file indicates what is the current working environment. Options are: 'production' and 'development';

b) It will read a config JSON file based on what is found in env file. If env is "production", the file is 'config.production.json'. If env is "development", the file is 'config.development.json'.

sim642 /
Last active Oct 20, 2020
Installing boost libraries for GCC (MinGW) on Windows

Installing boost libraries for GCC (MinGW) on Windows

Folder setup

  1. Extract downloaded boost source, e.g. C:\Program Files\boost_1_59_0.
  2. Create a folder for Boost.Build installation, e.g. C:\Program Files\boost-build.
  3. Create a folder within for building, i.e. C:\Program Files\boost_1_59_0\build.
  4. Create a folder for installation, e.g. C:\Program Files\boost.

GCC setup

  1. Open Command Prompt.
Rod-Persky / CMakeLists.txt
Created Oct 26, 2014
Example cmake for windows including auto copy dll
View CMakeLists.txt
cmake_minimum_required(VERSION 2.8.11)
set(CMAKE_PREFIX_PATH "C:/Qt/5.3/msvc2013_64/lib/cmake")
# Find the QtWidgets library
find_package(Qt5Widgets REQUIRED)
wbroek / genymotionwithplay.txt
Last active Sep 28, 2020
Genymotion with Google Play Services for ARM
View genymotionwithplay.txt
NOTE: Easier way is the X86 way, described on
Download the following ZIPs:
ARM Translation Installer v1.1 (
Download the correct GApps for your Android version:
Google Apps for Android 6.0 ( -
Google Apps for Android 5.1 ( -
Google Apps for Android 5.0 ( -
llbbl /
Last active Oct 21, 2020 — forked from ziadoz/
Awesome PHP Libraries and Resources

Awesome PHP

A list of amazingly awesome PHP libraries, resources and shiny things.


  • Composer
  • Composer Related
  • Frameworks
  • Micro Frameworks
You can’t perform that action at this time.