Skip to content

Instantly share code, notes, and snippets.

View terrymafura's full-sized avatar
🤖
trying not to be a robot

Terry terrymafura

🤖
trying not to be a robot
  • Worldwide
View GitHub Profile
@terrymafura
terrymafura / private_fork.md
Created July 13, 2023 20:04 — forked from 0xjac/private_fork.md
Create a private fork of a public repository

The repository for the assignment is public and Github does not allow the creation of private forks for public repositories.

The correct way of creating a private frok by duplicating the repo is documented here.

For this assignment the commands are:

  1. Create a bare clone of the repository. (This is temporary and will be removed so just do it wherever.)

git clone --bare [email protected]:usi-systems/easytrace.git

@terrymafura
terrymafura / kubectl_ubuntu_wsl.sh
Created January 9, 2020 12:54 — forked from cmendible/kubectl_ubuntu_wsl.sh
Install kubectl on ubuntu (WSL) and use kubectl config from Windows
#!/bin/bash
# Receives your Windows username as only parameter.
curl -LO https://storage.googleapis.com/kubernetes-release/release/v1.16.0/bin/linux/amd64/kubectl
chmod +x ./kubectl
sudo mv ./kubectl /usr/local/bin/kubectl
windowsUser=$1
@terrymafura
terrymafura / file_listener.sh
Created December 4, 2019 17:11
Bash script that waits for a file in a directory and processes it then zips
#!/bin/bash
TARGET=/<input_directory>
OUTPUT=/<output_directory>/
inotifywait -m -e create -e moved_to --format "%f" $TARGET \
| while read FILENAME
do
echo Detected $FILENAME, processing
# any instruction on the file here
@terrymafura
terrymafura / hyper.js
Created June 10, 2019 12:43
My Hyper Config
// Future versions of Hyper may add additional config options,
// which will not automatically be merged into this file.
// See https://hyper.is#cfg for all currently supported options.
module.exports = {
config: {
// choose either `'stable'` for receiving highly polished,
// or `'canary'` for less polished but more frequent updates
updateChannel: 'stable',
@terrymafura
terrymafura / .zshrc
Last active January 6, 2020 06:30
My WSL zsh config file
# Enable Powerlevel10k instant prompt. Should stay close to the top of ~/.zshrc.
# Initialization code that may require console input (password prompts, [y/n]
# confirmations, etc.) must go above this block, everything else may go below.
if [[ -r "${XDG_CACHE_HOME:-$HOME/.cache}/p10k-instant-prompt-${(%):-%n}.zsh" ]]; then
source "${XDG_CACHE_HOME:-$HOME/.cache}/p10k-instant-prompt-${(%):-%n}.zsh"
fi
# If you come from bash you might have to change your $PATH.
# export PATH=$HOME/bin:/usr/local/bin:$PATH
@terrymafura
terrymafura / upload.php
Created March 28, 2018 16:47 — forked from gayanhewa/upload.php
PHP Script to upload files via FTP
<?php
// Ref : http://php.net/manual/en/function.ftp-put.php
$name = "test.txt";
$filename = "/home/mine/Desktop/test.txt";
//-- Code to Transfer File on Server Dt: 06-03-2008 by Aditya Bhatt --//
//-- Connection Settings
$ftp_server = "server_url_here"; // Address of FTP server.
$ftp_user_name = "username_here"; // Username
@terrymafura
terrymafura / Dennis Ritchie - A great man.markdown
Created April 21, 2016 08:21
Dennis Ritchie - A great man