Skip to content

Instantly share code, notes, and snippets.

🎯
Focusing

Marc-André Appel marcandreappel

🎯
Focusing
Block or report user

Report or block marcandreappel

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View gist:9189422
git config --global alias.lg "log --color --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr)%C(bold blue)<%an>%Creset' --abbrev-commit"
@marcandreappel
marcandreappel / states_provinces.php
Created Aug 29, 2011
Concrete5 - Liste des départements de la France dans : helpers / lists / states_provinces.php, il faut remplacer le fichier (ou son contenu) par le fichier ci-dessous
View states_provinces.php
<?
/**
* @package Helpers
* @category Concrete
* @author Andrew Embler <andrew@concrete5.org>
* @copyright Copyright (c) 2003-2008 Concrete5. (http://www.concrete5.org)
* @license http://www.concrete5.org/license/ MIT License
*/
/**
View ionic2-pushwoosh.service.ts
import {Injectable} from "@angular/core";
import {Device} from 'ionic-native';
declare var cordova : any;
var PUSHWOOSH_APP_ID = 'XXXXX-XXXXX';
var GOOGLE_PROJECT_NUMBER = 'XXXXXXXXXXXXX';
// For iOS, open your project .pList file in xCode and add:
// 1) "Pushwoosh_APPID" key with the Pushwoosh App Id value
@marcandreappel
marcandreappel / ionic2-app.ts
Created Jul 18, 2016 — forked from EvanWillms/ionic2-app.ts
Ionic2 Pushwoosh app.ts sample
View ionic2-app.ts
import {Componente} from '@angular/core';
import {Platform, ionicBootstrap} from 'ionic-angular';
import {PushwooshService} from './services/pushwoosh.service';
@Component({
template: '<ion-nav [root]="rootPage" #ionNav></ion-nav>',
})
export class MyApp {
constructor(private platform:Platform,
View keybase.md

Keybase proof

I hereby claim:

  • I am marcandreappel on github.
  • I am marc_andre (https://keybase.io/marc_andre) on keybase.
  • I have a public key ASDdQQGvYkoMBTkkVtK9R6BQKNOkhGQ42exFy1yfBHjF4wo

To claim this, I am signing this object:

@marcandreappel
marcandreappel / xcode-build-bump.sh
Created Jul 23, 2017 — forked from sekati/xcode-build-bump.sh
Xcode Auto-increment Build & Version Numbers
View xcode-build-bump.sh
# xcode-build-bump.sh
# @desc Auto-increment the build number every time the project is run.
# @usage
# 1. Select: your Target in Xcode
# 2. Select: Build Phases Tab
# 3. Select: Add Build Phase -> Add Run Script
# 4. Paste code below in to new "Run Script" section
# 5. Drag the "Run Script" below "Link Binaries With Libraries"
# 6. Insure that your starting build number is set to a whole integer and not a float (e.g. 1, not 1.0)
@marcandreappel
marcandreappel / AppDelegate.swift
Created Jul 24, 2017 — forked from andreif/AppDelegate.swift
Example of UIPageViewController without storyboard i.e. created programmatically
View AppDelegate.swift
// derived from https://www.veasoftware.com/posts/uipageviewcontroller-in-swift-xcode-62-ios-82-tutorial
import UIKit
@UIApplicationMain
class AppDelegate: UIResponder, UIApplicationDelegate {
var window: UIWindow?
func application(application: UIApplication, didFinishLaunchingWithOptions launchOptions: [NSObject: AnyObject]?) -> Bool {
window = UIWindow(frame: UIScreen.mainScreen().bounds)
window!.rootViewController = ViewController()
@marcandreappel
marcandreappel / hmr-index.js
Created Aug 14, 2017 — forked from remy/hmr-index.js
A take on HMR. I don't remember exactly where it came from, but it works for me.
View hmr-index.js
import React from 'react';
import ReactDOM from 'react-dom';
import { Provider } from 'react-redux';
import store from './store';
const rootEl = document.getElementById('root');
// Create a reusable render method that we can call more than once
let render = () => {
// Dynamically import our main App component, and render it
View ubuntu-php-development-environment.md

#Introduction If you're a php developer on ubuntu, there comes the time where you have to install/reinstall your system. I did it already a few times and i decided to write down the steps for a typical web developer stack with php. This is for a developer machine and not for a live environment!

I hope it helps you too!

fyi @mheiniger and me started with an installer here: https://github.com/mheiniger/webdev-setup

@marcandreappel
marcandreappel / PeekingLinearLayoutManager.kt
Created Jun 16, 2019 — forked from bolot/PeekingLinearLayoutManager.kt
LinearLayoutManager subclass that "peeks", shows a portion of the adjacent child views.
View PeekingLinearLayoutManager.kt
class PeekingLinearLayoutManager : LinearLayoutManager {
@Suppress("Unused")
@JvmOverloads
constructor(context: Context?, @RecyclerView.Orientation orientation: Int = RecyclerView.VERTICAL, reverseLayout: Boolean = false) : super(context, orientation, reverseLayout)
@Suppress("Unused")
constructor(context: Context, attrs: AttributeSet, defStyleAttr: Int, defStyleRes: Int) : super(context, attrs, defStyleAttr, defStyleRes)
override fun generateDefaultLayoutParams() =
scaledLayoutParams(super.generateDefaultLayoutParams())
You can’t perform that action at this time.