Skip to content

Instantly share code, notes, and snippets.

View saqib1707's full-sized avatar
๐Ÿ‘‹

Saqib Azim saqib1707

๐Ÿ‘‹
View GitHub Profile
Collecting wrf-python==1.3.1 (from -r requirements.txt (line 21))
Downloading wrf-python-1.3.1.tar.gz (1.1 MB)
โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ” 1.1/1.1 MB 38.8 MB/s eta 0:00:00
Preparing metadata (setup.py) ... error
error: subprocess-exited-with-error
ร— python setup.py egg_info did not run successfully.
โ”‚ exit code: 1
โ•ฐโ”€> [6 lines of output]
Traceback (most recent call last):
@saqib1707
saqib1707 / Local_Github_Page_Setup_Guide.md
Last active September 4, 2024 04:37
This file provides step-by-step instructions for installing necessary packages for setting up local environment to test your github pages and sites.

Github Page Setup Guide Locally

Install Ruby (Recommended)

MacOS comes with Ruby installed, but it's usually a good idea to install a newer version and manage it through a version manager like rbenv or RVM. This avoids permission issues and makes it easier to manage different Ruby environments. If you encounter any permission issues during the installation (which can happen with the default Ruby installation on macOS), using a Ruby version manager like rbenv helps resolve these issues. It allows you to install gems without needing superuser privileges and makes managing Ruby environments easier.

  1. Using rbenv (recommended for simplicity):
brew install rbenv

Tips & Tricks for Unix Systems

iTerm2

  • Split terminal into two vertical panes: Cmd + D
  • Split terminal into two horizontal panes: Cmd + Shift + D

Macbook On-board Keyboard (proceed with caution using sudo)

  • Tested on Macbook Air 2017
  • To disable keyboard (in case on-board keyboard not functioning correctly):
@saqib1707
saqib1707 / python_virtual_env.md
Last active April 16, 2024 19:33
A brief description of Python Virtual Environments

Python Virtual Environments

A python virtual environment is a lighweight tool used to create an isolated Python environment with its own -

  • Package directories that doesn't share libraries with other virtual environments
  • Python binary (either copied or linked from the python environment used to create the virtual env)
  • optionally doesn't access the globally installed libraries either

Note: venv is a package that comes only with Python3.x and not with Python2.x.

  1. To create a python virtual environment:
#!/bin/bash
# find_and_replace.sh
echo "Find and replace in current directory!"
echo "File pattern to look for? (eg '*.txt')"
read filepattern
echo "Existing string?"
read existing
echo "Replacement string?"
read replacement
@saqib1707
saqib1707 / sed-cheatsheet.md
Created January 11, 2020 06:26 — forked from sergeyklay/sed-cheatsheet.md
Sed Cheatsheet

Sed Cheat Sheet

Sed command line options

sed [options] sed-command [input-file]
Option Description Example
@saqib1707
saqib1707 / find.sh
Created January 11, 2020 06:24 — forked from gr1ev0us/find.sh
Cheatsheet for find linux
# List of cheatsheet for linux find.
# Taken from here http://alvinalexander.com/unix/edu/examples/find.shtml
# basic 'find file' commands
# --------------------------
find / -name foo.txt -type f -print # full command
find / -name foo.txt -type f # -print isn't necessary
find / -name foo.txt # don't have to specify "type==file"
find . -name foo.txt # search under the current dir
find . -name "foo.*" # wildcard
@saqib1707
saqib1707 / gcc-5.4.0-install.sh
Created October 31, 2019 01:51 — forked from jdhao/gcc-5.4.0-install.sh
The script will install GCC 5.4.0 on your CentOS 7 system, make sure you have root right. See https://jdhao.github.io/2017/09/04/install-gcc-newer-version-on-centos/ for more details.
echo "Downloading gcc source files..."
curl https://ftp.gnu.org/gnu/gcc/gcc-5.4.0/gcc-5.4.0.tar.bz2 -O
echo "extracting files..."
tar xvfj gcc-5.4.0.tar.bz2
echo "Installing dependencies..."
yum -y install gmp-devel mpfr-devel libmpc-devel
echo "Configure and install..."