Skip to content

Instantly share code, notes, and snippets.

View rrrokhtar's full-sized avatar
🇵🇸
Free Palestine

Mokhtar rrrokhtar

🇵🇸
Free Palestine
View GitHub Profile
@rrrokhtar
rrrokhtar / settings.json
Created August 5, 2024 18:21
VSCode SAM yaml config
{
"yaml.customTags": [
"!Equals sequence",
"!FindInMap sequence",
"!GetAtt",
"!GetAZs",
"!ImportValue",
"!Join sequence",
"!Ref",
"!Select sequence",
@rrrokhtar
rrrokhtar / HackHtml.md
Created July 23, 2024 20:41
Web document design mode (editable HTML)
javascript:document.body.contentEditable = 'true'; document.designMode='on'; void 0
@rrrokhtar
rrrokhtar / aged.sh
Created February 16, 2024 11:39
PostgreSQL (13.3) and apache age (1.3.0) Fresh Install Script
mkdir aged
cd aged
export cwd=$(pwd)
wget https://ftp.postgresql.org/pub/source/v13.3/postgresql-13.3.tar.gz
tar xzf postgresql-13.3.tar.gz
cd postgresql-13.3/
mkdir data
chown $(whoami) data
@rrrokhtar
rrrokhtar / README.md
Created November 13, 2023 06:26
GIT COMMON FORGOTS
  1. Ignore file locally
git update-index --skip-worktree <file-list>
git update-index --no-skip-worktree <file-list>
  1. Add to .ignore index locally ('/.vscode/*') for example
echo '/.vscode/*' >> .git/info/exclude
sudo apt-get install libgl1-mesa-dev
@rrrokhtar
rrrokhtar / PNSI-RTE.md
Last active June 3, 2023 14:50
PG13 PNSI vs RTE

1- I started when the project started (learned some along the way some parts and already have been good with other parts)

2- I have picked the project based on my previous experience and skills alongside the project's criteria

3- Have no contribution to any open-source project yet? is okay as long as you are having the required experience

4- Nothing is late just start with whatever you want to start with

5- If you start early, you get more chance to get accepted for sure

@rrrokhtar
rrrokhtar / setup-python3.8-via-ppa.sh
Created March 2, 2023 19:29 — forked from ptantiku/setup-python3.8-via-ppa.sh
Setup Python3.8 in Ubuntu Xenial (16.04 LTS). The python version was fixed at Python 3.5.1
#!/bin/sh
# install PPA
sudo add-apt-repository ppa:deadsnakes/ppa
# update and install
sudo apt update
sudo apt install python3.8 python3.8-dev python3.8-venv
# setup alternatives
@rrrokhtar
rrrokhtar / flask_sitemap_generator.py
Created December 7, 2022 22:52 — forked from Julian-Nash/flask_sitemap_generator.py
Flask dynamic sitemap generator
@app.route("/sitemap")
@app.route("/sitemap/")
@app.route("/sitemap.xml")
def sitemap():
"""
Route to dynamically generate a sitemap of your website/application.
lastmod and priority tags omitted on static pages.
lastmod included on dynamic content such as blog posts.
"""
from flask import make_response, request, render_template
@rrrokhtar
rrrokhtar / load_dotenv.sh
Created November 21, 2022 13:38 — forked from mihow/load_dotenv.sh
Load environment variables from dotenv / .env file in Bash
if [ ! -f .env ]
then
export $(cat .env | xargs)
fi