Skip to content

Instantly share code, notes, and snippets.

View MichaelCurrin's full-sized avatar

Michael Currin MichaelCurrin

  • The Netherlands
View GitHub Profile
@MichaelCurrin
MichaelCurrin / bar.md
Last active April 22, 2020 12:58
Demo of multi-file gist with internal links

Bar

The order seems alphabetical for files.

@MichaelCurrin
MichaelCurrin / python_sqlite_demo.py
Last active May 3, 2020 14:11
Insert tweet data into a database using SQLite
"""
Python SQLite demo.
The sqlite3 library is a Python builtin. Read more in the Python 3 docs:
https://docs.python.org/3/library/sqlite3.html
See also the SQLite docs:
https://www.sqlite.org/docs.html
"""
import sqlite3
@MichaelCurrin
MichaelCurrin / install_graphics_magick.md
Last active May 25, 2020 08:42
How to install GraphicsMagick
@MichaelCurrin
MichaelCurrin / linux-os-flavors.md
Created June 5, 2020 12:11
Popular flavors of Linux
  • Debian

    Debian, also known as Debian GNU/Linux, is a Linux distribution composed of free and open-source software, developed by the community-supported Debian Project, which was established by Ian Murdock on August 16, 1993.

  • Ubuntu
    • Based on Debian.

    Ubuntu is an open source software operating system that runs from the desktop, to the cloud, to all your internet connected things

  • Linux Mint

    Linux Mint is a community-driven Linux distribution based on Ubuntu or Debian. Linux Mint comes bundled with a variety of free and open-source applications and can provide full out-of-the-box multimedia support for those who choose to include some proprietary software, such as multimedia codecs.

  • Linux Lite > Linux Lite is a Linux distribution, based on Debian and Ubuntu and created by a team led by Jerry Bezencon. The distribution offers a lightweight desktop experience with a customiz
@MichaelCurrin
MichaelCurrin / applications.md
Last active June 5, 2020 12:31
Reference for applications I like to install on Linux / macOS mostly for software development

Applications

Linux or macOS

  • Insomnia
  • Postman

Linux

@MichaelCurrin
MichaelCurrin / random-alias-of-the-day.md
Created June 20, 2020 21:45
Random alias of the day

Why?

Too many aliases to remember all at once? Teach or remind yourself of one at a time.

On opening a new terminal window, show a random alias from your aliases and git aliases.

This is your IDE's tip of the day but in your terminal.

Follow instructions in this gist to setup.

@MichaelCurrin
MichaelCurrin / test_cases.txt
Last active June 23, 2020 14:50
Extract URLs by regex
Welcome to RegExr 0.3b, an intuitive tool for learning, writing, and testing Regular Expressions. Key features include:
www.google.com
* real time results: shows results as you type
* code hinting: roll over your expression to see info on specific elements
* detailed results: roll over a match to see details & view group info below
* built in regex guide: double click entries to insert them into your expression
* online & desktop: regexr.com or download the desktop version for Mac, Windows, or Linux
* save your expressions: My Saved expressions are saved locally
* search Comm https://google.us.edi?34535/534534?dfg=g&fg unity expressions and add your own
* create Share Links to send your expressions to co-workers or link to them on Twitter or your blog [ex. http://RegExr.com?2rjl6]
@MichaelCurrin
MichaelCurrin / submodules.md
Last active June 28, 2020 14:05
Git submodules reference

An intro and cheatsheet for using git submodules.

Add submodule to project

$ git submodule add https://github.com/USERNAME/REPONAME PATH

e.g.

@MichaelCurrin
MichaelCurrin / run_docsify_locally.md
Last active September 1, 2020 19:00
Serve a docs site locally with DocsifyJS

Serve a docs site locally with DocsifyJS

Choose an option below depending on whether you want to install and run Docsify CLI (optional), or use another server. Either way, you serve the docs directory.

Docsify CLI
  1. Install NodeJS.
  2. Install Docsify CLI
@MichaelCurrin
MichaelCurrin / freeze_short
Last active September 5, 2020 16:49
Pip freeze alternative
#!/usr/bin/env python3
"""
Pip freeze alternative.
Show exact versions of Python packages in a virtual environment, matching
ONLY libraries named in the requirements file, in order to give a shorter version
of pip freeze output.
The logic in this script:
- requirements.txt doesn't always have versions or exact versions it.