Skip to content

Instantly share code, notes, and snippets.

View Halleck45's full-sized avatar

Jean-François Lépine Halleck45

View GitHub Profile
@Halleck45
Halleck45 / install-ubuntu.sh
Last active August 16, 2018 09:16
install-ubuntu.sh
#!/bin/bash
function pause(){
read -p "$*"
}
# Common packages
sudo apt-get install -y vim wget git nodejs npm curl php terminator
# IDE
wget https://download.jetbrains.com/webide/PhpStorm-2017.3.2.tar.gz -O phpstorm.tar.gz
@Halleck45
Halleck45 / youbora1.php
Created September 12, 2017 08:19
Youbora support
<?php
// This file concerns Youbora support
$secretKey = 'mysecret';
$system = 'system'
$url = '/quality/top?system='.$system.'&timezone=Europe/Paris&type=&asc=true&orderBy=plays&startDate=&endDate=';
$expirationTime = round(microtime(true) * 1000) + 1800000;
$preurl = $url . "&dateToken=".$expirationTime;
@Halleck45
Halleck45 / rf-profil-dev.md
Last active September 11, 2017 13:24
Fiche de poste développeur assurance qualité

Nous recherchons un développeur web pour aider notre équipe qualité dans son travail quotidien et l’accompagner dans le développements de solutions spécifiques.

Mission :

  • Développements d’outils et de solutions spécifiques pour l’équipe assurance qualité
  • Aider et conseiller les équipes d’industrialisation
  • Aider et accompagner les équipes de développement (PHP, NodeJs, Android et IOS)

Environnent technique :

@Halleck45
Halleck45 / npm-debug.log
Created February 2, 2017 15:06
spark-install-error
04:01:07 /var/www$ cat /var/www/spark/npm-debug.log
0 info it worked if it ends with ok
1 verbose cli [ '/usr/bin/node', '/usr/bin/npm', 'run', 'dev' ]
2 info using [email protected]
3 info using [email protected]
4 verbose node symlink /usr/bin/node
5 verbose run-script [ 'predev', 'dev', 'postdev' ]
6 info predev @
7 info dev @
8 verbose unsafe-perm in lifecycle true
@Halleck45
Halleck45 / process.md
Last active November 28, 2015 13:04
Github migration results

## Steps

  • Creation of Halleck45/tmp-migration

  • Creation of README.md with

    # tmp-migration
    fgh
    
@Halleck45
Halleck45 / php-grep.sh
Created November 25, 2015 15:20
php-grep.sh
#!/bin/bash
# Metrics for PHP
#
# author: Jean-François Lépine
echo "PHPMetrics, by Jean-François Lépine"
echo
@Halleck45
Halleck45 / phpmetrics.js
Last active December 1, 2015 12:29 — forked from devosc/phpmetrics.js
//http://slimerjs.org/
var page = require('webpage').create();
page.viewportSize = { width:1280, height:800 };
page.open('http://localhost/phpmetrics.html')
.then(function(){
window.setTimeout(function() {
@Halleck45
Halleck45 / pick-iframe.html
Created December 22, 2014 15:44
pick Jenkins monitor table
<iframe id="frame-monitor" style="display:none; " src="http://jenkins.xxxx.fr/view/Administration/job/Administration%20-%20Monitoring/2/sitemonitor/"></iframe>
<div id="div-monitor"></div>
<script type="text/javascript">
var iframe = document.getElementById('frame-monitor');
iframe.onload = function() {
var innerDoc = (iframe.contentDocument) ? iframe.contentDocument : iframe.contentWindow.document;
var table = innerDoc.getElementById('files');
var container = document.getElementById('div-monitor');
container.appendChild (table);
iframe.parentNode.removeChild( iframe );
@Halleck45
Halleck45 / licenses-violations.php
Last active August 29, 2015 14:05
Check licenses violations
<?php
// Usage
// composer licenses --format=json > licenses.json
// php analyze.php --file=licenses.json
$options = getopt('', array('file'));
$file = $options['file'];
$json = json_decode(file_get_contents($file));
@Halleck45
Halleck45 / Csrf.php
Created July 28, 2014 09:56
Minimal protection against CRSF exploit without changing any file
<?php
/**
* Class SecurityException
*/
class SecurityException extends Exception {};
/**
* Class Csrf
*