Skip to content

Instantly share code, notes, and snippets.

View mehdinourollah's full-sized avatar
🏠
Working from home

Mehdi Nourollah mehdinourollah

🏠
Working from home
View GitHub Profile
@mehdinourollah
mehdinourollah / mysession.js
Created October 9, 2018 13:19
I used this for session in Express+hbs
var express = require('express');
var cookieParser = require('cookie-parser');
var session = require('express-session');
var app = express();
app.use(cookieParser());
app.use(session({secret: "Shh, its a secret!"}));
app.get('/', function(req, res){
npm config set proxy http://127.0.0.1:1080
npm config set https-proxy http://127.0.0.1:1080
npm config set proxy http://127.0.0.1:1080
npm config set https-proxy http://127.0.0.1:1080
@mehdinourollah
mehdinourollah / resign.sh
Created April 21, 2020 13:26 — forked from RichardBronosky/resign.sh
A simple tool for resigning an iOS app ipa with a new certificate/mobileprovision
#!/usr/bin/env bash
if [[ ! ( # any of the following are not true
# 1st arg is an existing regular file
-f "$1" &&
# ...and it has a .ipa extension
"${1##*.}" == "ipa" &&
# 2nd arg is an existing regular file
-f "$2" &&
# ...and it has an .mobileprovision extension

Keybase proof

I hereby claim:

  • I am mehdinourollah on github.
  • I am meikineumann (https://keybase.io/meikineumann) on keybase.
  • I have a public key ASATAbNV1DcubcLTuidVf-5AuQi04ZQxs72TCyPTthDmYQo

To claim this, I am signing this object:

{
"basics":{
"name":"Mehdi Nourollah",
"label":"Sofware engineer",
"picture":"",
"email":"mehdinourollah@gmail.com",
"phone":"(+49)15150353331",
"website":"http://mehdinourollah.github.io",
"summary":"Fullstack Developer Mobile Developer Javascript React-Native, Flutter and low level programing enthusiast",
"location":{
@mehdinourollah
mehdinourollah / listlayer.xml
Created December 7, 2020 15:37 — forked from srayhunter/listlayer.xml
Android List-Layer Drawable with VectorDrawable Text
<?xml version="1.0" encoding="utf-8"?>
<layer-list xmlns:android="http://schemas.android.com/apk/res/android">
<item android:state_checked="true">
<shape>
<solid android:color="@android:color/white"/>
<corners android:radius="5dp"/>
</shape>
</item>
<item android:drawable="@drawable/vector"/>
</layer-list>
data:text/html, <textarea style="font-size: 1.5em; width: 100%; height: 100%; border: none; outline: none" autofocus />
@mehdinourollah
mehdinourollah / browser.txt
Created March 26, 2021 06:57 — forked from pankajparashar-zz/browser.txt
One line browser notepad
Version 1
---------
data:text/html, <html contenteditable>
Version 2
---------
data:text/html, <html><head><link href='http://fonts.googleapis.com/css?family=Open+Sans' rel='stylesheet' type='text/css'><style type="text/css"> html { font-family: "Open Sans" } * { -webkit-transition: all linear 1s; }</style><script>window.onload=function(){var e=false;var t=0;setInterval(function(){if(!e){t=Math.round(Math.max(0,t-Math.max(t/3,1)))}var n=(255-t*2).toString(16);document.body.style.backgroundColor="#ff"+n+""+n},1e3);var n=null;document.onkeydown=function(){t=Math.min(128,t+2);e=true;clearTimeout(n);n=setTimeout(function(){e=false},1500)}}</script></head><body contenteditable style="font-size:2rem;line-height:1.4;max-width:60rem;margin:0 auto;padding:4rem;">
Version 3
---------
@mehdinourollah
mehdinourollah / node_reinstall_macos.txt
Created April 6, 2021 10:00 — forked from dotcomputercraft/gist:b7283bd52f4b5389e748
How do I completely uninstall Node.js, and reinstall from beginning (Mac OS X)
the best way (I've found) to completely uninstall node + npm is to do the following:
go to /usr/local/lib and delete any node and node_modules
go to /usr/local/include and delete any node and node_modules directory
if you installed with brew install node, then run brew uninstall node in your terminal
check your Home directory for any local or lib or include folders, and delete any node or node_modules from there
go to /usr/local/bin and delete any node executable
You may need to do the additional instructions as well:
sudo rm /usr/local/bin/npm