Skip to content

Instantly share code, notes, and snippets.

View justinhartman's full-sized avatar
🏠
Working from home

Justin Hartman justinhartman

🏠
Working from home
View GitHub Profile
@justinhartman
justinhartman / add_domains_install-log
Created June 9, 2018 14:16
Release v0.5.0 Build Log
$ sudo ./add_domains
----------------------------------------------
| |
| Add domain to 'openssl.conf' configuration |
| file. |
| |
----------------------------------------------
./scripts/openssl_config.sh: line 45: $ssl/openssl.conf: No such file or directory
DNS.1 = localhost
DNS.2 = *.localhost
@justinhartman
justinhartman / git-extra-summary.md
Created May 20, 2018 19:15
Git Extra Commands Summary

COMMANDS

  • git-alias: Define, search and show aliases
  • git-archive-file: Export the current HEAD of the git repository to an archive
  • git-authors: Generate authors report
  • git-back: Undo and Stage latest commits
  • git-bug: Create bug branch
  • git-bulk: Run git commands on multiple repositories
  • git-changelog: Generate a changelog report
  • git-chore: Create chore branch
  • git-clear: Rigorously clean up a repository
@justinhartman
justinhartman / macos-terminal-commands.md
Last active November 7, 2018 10:06
Useful macOS Terminal Commands

Useful macOS Terminal Commands

The following commands I will be using in the https://github.com/justinhartman/Automated-LAMP-with-trusted-localhost-SSL project but they are also useful commands to keep as a reference.

Import certificates into the System Keychain

$ sudo security add-trusted-cert -d -r trustRoot -k /Library/Keychains/System.keychain <certificate>
$ sudo security add-trusted-cert -d -r trustRoot -k $HOME/Library/Keychains/login.keychain <certificate>
@justinhartman
justinhartman / aliases.md
Created May 17, 2018 14:06
Aliases in Use on MacBook Pro

Filesystem

Shortcut Command
- 'cd -'
... ../..
.... ../../..
..... ../../../..
...... ../../../../..
@justinhartman
justinhartman / shortcut-commands.md
Created May 17, 2018 00:55
Common Development Terminal Commands

Git

Shortcut Command
gsb git status -s
gaa 'git add --all'
gcmsg 'git commit -m'
gcam 'git commit -a -m'
gp ’git push'
gcl 'git clone --recursive'
ggpull 'git pull origin $(git_current_branch)'
@justinhartman
justinhartman / xcode-gitignore-response.md
Created May 5, 2018 19:39
Xcode .gitignore template response to PR in @github/gitignore

Apologies for taking so long to respond to your question. It's been a long time since I made these changes so I'll try my best to explain it all 😄.

1. *.xcodeproj/

There is a good [thread over here][1] that gets into some more specifics but the issue with excluding the .xcodeproj/ in its entirety is that you are excluding files that shouldn't be excluded and may need to be shared across development team members. The additional rules I added address this problem of simply excluding the entire folder.

.xcodeproj/ structure

In order to address the additional rules I added in [patch-1][patch] I have included the follow tree output of an Xcode project; in particular, the .xcodeproj/ folder. I will use this to reference rules #2, #3 and #4 below.

@justinhartman
justinhartman / xscheme-example-file.xml
Last active May 5, 2018 19:48
The LicensesViewController.xcscheme file containing key configuration options.
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "0910"
version = "1.3">
<BuildAction
parallelizeBuildables = "YES"
buildImplicitDependencies = "YES">
<BuildActionEntries>
<BuildActionEntry
buildForTesting = "YES"
@justinhartman
justinhartman / curl-retry-resume.md
Created March 14, 2018 14:12
cURL retries and file-resume command

cURL retries and file-resume command

Because I need to be able to download files with the option to resume with our shitty South African Internet connectivity.

$ curl -O -C - --retry 4 --progress-bar "FILE_URL"
@justinhartman
justinhartman / php-301-redirect.php
Created March 7, 2018 15:31
301 Permanent Redirect in PHP
<?php
header("HTTP/1.1 301 Moved Permanently");
header("Location: https://22digital.agency");
exit();