Skip to content

Instantly share code, notes, and snippets.

View waqashamid's full-sized avatar
🎯
Focusing

Waqas Hamid waqashamid

🎯
Focusing
View GitHub Profile
@waqashamid
waqashamid / pre-commit-hook.sh
Last active September 15, 2020 08:39
pre-commit-hook.sh
#### Important Git information
Before you start committing code, please install our pre-commit hook for Git, which will check for code quality issues
(as per PEP8 conventions) and imports sorted incorrectly.
The file `pre-commit-hook.sh` is the hook script. To install this in your local repository, you need to symlink the script
in your ``.git/hooks`` folder.
The following commands will create the link.
@waqashamid
waqashamid / python_selenium.MD
Created July 11, 2020 12:16
[Selenium and python for PDF]

How To Install Selenium Chrome On Centos 7 Last Updated: 2020-05-23

Installing Chrome and Selenium can be quite challenging. This post goes through step by step tutorial to install Selenium and Chrome. I have also put together a small section at the end to cover "most commonly errors" during installation. Lets get started now.

Lets install first Chrome.

How to install Chrome On Centos 7 wget https://dl.google.com/linux/direct/google-chrome-stable_current_x86_64.rpm Lets install chrome now.

# Check coverage:
* coverage run --source=. manage.py test -v 2
@waqashamid
waqashamid / useful_git
Last active July 11, 2020 06:36
[Useful GIT commands]
# You might need to start ssh-agent before you run the ssh-add command:
eval `ssh-agent -s`
ssh-add
# Lists already added identities (‘ssh keys’)
ssh-add -l
Then, if you don't see your key listed, add it with the following (replace identity with its real name):
# Add a new identity
@waqashamid
waqashamid / merge
Created May 17, 2018 06:50 — forked from tmiller/merge
Bash script to merge master into all branches
#!/bin/bash
# Merges the master branch into all other branches
#
# Process:
#
# - Save the name of the current branch
# - If the current branch is not master then checkout master.
# - Pull the latest changes for master from its upstream branch.
# - Loop over each local branch.