Skip to content

Instantly share code, notes, and snippets.

View floriancourgey's full-sized avatar
🐔
Supporting French Tech since 2010

Florian Courgey floriancourgey

🐔
Supporting French Tech since 2010
View GitHub Profile
@floriancourgey
floriancourgey / .vimrc
Last active January 26, 2023 00:03
~/.vimrc
" UI
set number " show line number
set ruler " show status bar
set laststatus=2 " always show status bar
syntax on " syntax based on extension
colorscheme slate " theme
set so=7 " set lines to show (when curosr at top or bottom of screen)
" Data
set encoding=utf8 " encoding
@floriancourgey
floriancourgey / setup.sh
Last active December 12, 2016 17:39
Setup pour la VM du TP linux
# SSH
apt install openssh-server
#### configurer Virtual box pour le SSH ###
# machine > settings > network > advanced > port forwarding
# rule 1 : 3022 vers 22
# puis depuis l'hote
# ssh -p 3022 florian@127.0.0.1
# apt update & installation d'utilitaires
@floriancourgey
floriancourgey / dockerfile-monphp5.5
Last active March 12, 2017 18:28
Dockerfile pour un serveur LAMP utilisé dans la plupart de mes projets web
# PHP 5.5 avec apache
# basé sur debian:jessie 8.6
FROM php:5.5-apache
# apps
RUN apt update && \
apt install -y \
apt-utils \
vim \
git \
@floriancourgey
floriancourgey / setup-elementary.sh
Last active September 5, 2018 05:51
Things to do after installing elementary OS Loki 0.4
# chromium
sudo apt install -y chromium-browser
# dev (php, docker, git, node, bower, electron, composer)
sudo apt install -y \
php php-curl php-mysql \
docker.io \
git \
nodejs npm
sudo ln -s /usr/bin/nodejs /usr/bin/node
@floriancourgey
floriancourgey / index.php
Created October 14, 2015 08:46
Formation SI - bot de connexion - base
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>PhpFiddle Initial Code</title>
</head>
<body>
<?php
@floriancourgey
floriancourgey / httpConnection.java
Last active September 30, 2015 19:08
Android > rev 23 Http connection
AsyncHttpClient client = new AsyncHttpClient(); // import com.loopj.android.http.AsyncHttpClient;
String stringCookies = CookieManager.getInstance().getCookie(url);
Log.e(TAG, stringCookies);
client.addHeader(SM.COOKIE, stringCookies); // import cz.msebera.android.httpclient.cookie.SM;
// décommenter la section suivante quand web debuging avec Fiddler
// on oublie pas l'import com.loopj.android.http.MySSLSocketFactory
/*
try {
KeyStore trustStore = KeyStore.getInstance(KeyStore.getDefaultType());
trustStore.load(null, null);
@floriancourgey
floriancourgey / context.php
Last active August 29, 2015 14:18
NewbieContest php curl connexion
<!DOCTYPE html>
<html>
<head>
<title><?= $titre ?></title>
<meta charset="UTF-8">
</head>
<body>
<?php
define("SMFCookie89", "");