Skip to content

Instantly share code, notes, and snippets.

View youaftouh's full-sized avatar

Yasser Ouaftouh youaftouh

View GitHub Profile
@youaftouh
youaftouh / publish-npm-package.md
Created February 2, 2026 02:06
Publish npm package

Publishing Guide for my-package

Prerequisites

Before publishing, ensure you have:

  • An npm account (sign up at https://www.npmjs.com/signup)
  • The package is ready (all tests pass, build successful)
  • You are logged into npm on your machine

Step-by-Step Publishing Instructions

@youaftouh
youaftouh / ArchiSteamFarm-android.md
Last active June 6, 2025 14:47
This is easy step-by-step-guide how to run ArchiSteamFarm on Android via Termux
@youaftouh
youaftouh / motion_webcam-stream.md
Last active November 6, 2020 17:50 — forked from endolith/readme.md
How to stream a webcam to a web browser in Ubuntu

Grr this took hours to figure out. I was trying to install MJPG-streamer and running VLC command lines and all this crap but nothing worked.

First install motion:

~> sudo apt-get install motion

Then create a config file:

~> mkdir ~/.motion

~> nano ~/.motion/motion.conf

@youaftouh
youaftouh / soundex.js
Created August 17, 2016 13:30 — forked from shawndumas/soundex.js
Soundex in JavaScript
var soundex = function (s) {
var a = s.toLowerCase().split(''),
f = a.shift(),
r = '',
codes = {
a: '', e: '', i: '', o: '', u: '',
b: 1, f: 1, p: 1, v: 1,
c: 2, g: 2, j: 2, k: 2, q: 2, s: 2, x: 2, z: 2,
d: 3, t: 3,
l: 4,
@youaftouh
youaftouh / CORSFilter.java
Created June 17, 2016 11:04 — forked from zeroows/CORSFilter.java
To enable CORS support in Spring MVC 4 - Access-Control-Allow-Origin
package com.elm.mb.rest.filters;
import java.io.IOException;
import javax.servlet.FilterChain;
import javax.servlet.ServletException;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import org.apache.commons.logging.Log;
@youaftouh
youaftouh / image-magic_media-conversion
Created June 16, 2016 21:14
Image Magic : media conversion using commands [under linux]
# repertoire du fichier tar contenant les images issues a l'ancien format
tarFolder=/media/hybris-media/phoenix/migration
# repertoire de travail ou seront extraites les images originales
mediaFolderOrigin=/media/hybris-media/phoenix/migration/original
# repertoire de travail ou seront converties les images originales
mediaFolderConverted=/media/hybris-media/phoenix/migration/converted
# repertoire contenant l'executable imageMagick