Skip to content

Instantly share code, notes, and snippets.

View Rizwan-Hasan's full-sized avatar
🌏
Working remotely

Rizwan Hasan Rizwan-Hasan

🌏
Working remotely
View GitHub Profile
@Rizwan-Hasan
Rizwan-Hasan / config
Last active May 10, 2018 17:51 — forked from rbialek/config
ssh/.config
Host github.com
User Rizwan-Hasan
Hostname github.com
PreferredAuthentications publickey
IdentityFile /home/rizwan/.ssh/magpie.id_rsa
@Rizwan-Hasan
Rizwan-Hasan / onedark.theme
Created September 11, 2018 10:15 — forked from fluxrad/onedark.theme
A one-dark theme for xfce4-terminal
[Scheme]
Name=One Dark
ColorForeground=#ABB2BF
ColorCursor=#ABB2BF
ColorBackground=#282C34
ColorSelection=#3B4451
ColorSelectionUseDefault=FALSE
ColorBold=#B9C0CB
ColorBoldUseDefault=FALSE
ColorPalette=#282C34;#E06C75;#98C379;#E5C07B;#61AFEF;#C678DD;#56B6C2;#ABB2BF;#3E4452;#BE5046;#98C379;#D19A66;#61AFEF;#C678DD;#56B6C2;#5C6370
@Rizwan-Hasan
Rizwan-Hasan / uefisetup.sh
Created January 10, 2019 19:54 — forked from Apsu/uefisetup.sh
Arch Linux UEFI Setup
# **************** READ THIS FIRST ******************
#
# This is not a script for you to run. I repeat, do not download and run this!
#
# This is only a guide to show the required steps for successful UEFI + GRUB2 installation
# Many of the choices are examples or assumptions; don't blindly type shit into your machine
# until/unless you at least read the comments around each command
#
# These steps assume you've booted in UEFI mode by preparing your USB stick per these instructions:
# https://wiki.archlinux.org/index.php/UEFI#Archiso
@Rizwan-Hasan
Rizwan-Hasan / git-clearHistory
Created June 2, 2019 13:48 — forked from stephenhardy/git-clearHistory
Steps to clear out the history of a git/github repository
-- Remove the history from
rm -rf .git
-- recreate the repos from the current content only
git init
git add .
git commit -m "Initial commit"
-- push to the github remote repos ensuring you overwrite history
git remote add origin git@github.com:<YOUR ACCOUNT>/<YOUR REPOS>.git
@Rizwan-Hasan
Rizwan-Hasan / README.md
Created June 6, 2019 16:16 — forked from lopspower/README.md
Hexadecimal color code for transparency

Hexadecimal color code for transparency

Twitter

How to set transparency with hex value ?

For example, you want to set 40% alpha transparence to #000000 (black color), you need to add 66 like this #66000000.

All hex value from 100% to 0% alpha:

@Rizwan-Hasan
Rizwan-Hasan / fix-git-line-endings
Created August 30, 2019 21:56 — forked from ajdruff/fix-git-line-endings
Forces all line endings to LF in your git repo.
#####################
#
# Use this with or without the .gitattributes snippet with this Gist
# create a fixle.sh file, paste this in and run it.
# Why do you want this ? Because Git will see diffs between files shared between Linux and Windows due to differences in line ending handling ( Windows uses CRLF and Unix LF)
# This Gist normalizes handling by forcing everything to use Unix style.
#####################
# Fix Line Endings - Force All Line Endings to LF and Not Windows Default CR or CRLF
@Rizwan-Hasan
Rizwan-Hasan / pyside2_qrunnable_signal_test.py
Created February 21, 2020 10:33 — forked from dalejfer/pyside2_qrunnable_signal_test.py
Run a QTheadPool with signal emitting QRunnable workers. Capture the signals in the main thread and update the UI.
#!python3.7
import random
import time
import PySide2
from PySide2 import QtCore, QtWidgets
from PySide2.QtCore import Slot, Signal, QObject, QThreadPool, QRunnable
class MyEmitter(QObject):
@Rizwan-Hasan
Rizwan-Hasan / dark_fusion.py
Last active February 25, 2020 18:32 — forked from lschmierer/dark_fusion.py
Qt5 Dark Fusion Palette for Python
qApp.setStyle(QStyleFactory.create("Fusion"))
darkPalette = QPalette()
darkColor = QColor(45, 45, 45)
disabledColor = QColor(127, 127, 127)
darkPalette.setColor(QPalette.Window, darkColor)
darkPalette.setColor(QPalette.WindowText, Qt.white)
darkPalette.setColor(QPalette.Base, QColor(40, 40, 40))
darkPalette.setColor(QPalette.AlternateBase, darkColor)
# ~/.config/systemd/user/jupyter.service
[Unit]
Description=An interactive python notebook server
After=network.target

[Service]
ExecStart=/usr/bin/jupyter notebook\
    --no-browser\
 --port=8001\
@Rizwan-Hasan
Rizwan-Hasan / git-io-custom-url.md
Created December 21, 2020 16:22 — forked from dikiaap/git-io-custom-url.md
git.io custom URL

Command:

curl https://git.io/ -i -F "url=https://github.com/YOUR_GITHUB_URL" -F "code=YOUR_CUSTOM_NAME"

URLs that can be created is from:

  • https://github.com/*
  • https://*.github.com
  • https://*.github.com/*
  • https://*.github.io