Skip to content

Instantly share code, notes, and snippets.

View ierceg's full-sized avatar

Ivan Erceg ierceg

View GitHub Profile
@ierceg
ierceg / jenkins_ec2_slave.md
Created December 15, 2017 00:22 — forked from tfoote/jenkins_ec2_slave.md
Installing jenkins on an EC2 Windows slave
  • Create a Windows instance
  • Use the aws console to get username and password
  • log in via rdp
  • Turn off IE Enhanced security control
  • Open server settings, local server, turn it off
  • install chrome
  • Install java: https://www.java.com/en/download/
  • Create C:\Jenkins
  • go to jenkins instance
  • log in as admin
### Keybase proof
I hereby claim:
* I am ierceg on github.
* I am ierceg (https://keybase.io/ierceg) on keybase.
* I have a public key ASD9oiteKy0QvDlEto0XrP6hFcFcTDnu8CZLKFnYPsqxvQo
To claim this, I am signing this object:
@ierceg
ierceg / github_gitlab_gpg_key.md
Last active August 14, 2022 10:26 — forked from ankurk91/github_gpg_key.md
Signing git commits using GPG (Ubuntu/Mac)

Github/GitLab : Signing commits using GPG (Ubuntu/Mac) 🔐

  • Do you have an Github/GitLab account ? If not create one.
  • Install required tools
  • Latest Git Client
  • gpg tools
# Ubuntu
sudo apt-get install gpa seahorse
# MacOS with https://brew.sh/
@ierceg
ierceg / split-branch.sh
Last active December 29, 2023 20:46
Split branch into multiple PRs based on selected files, not commits
#!/bin/sh
# TODO:
# - Allow for splitting the same file into multiple branches.
# - If there are manual commits apart from the automatic merges and (split-branch) commits, <do something>. `git merge-base` is useful here.
# Design:
# - The script should be run from the branch that is being split.
# - The script accepts the target branch as an argument.
# - The script will automatically merge the target branch into the source branch if needed.
@ierceg
ierceg / git-merge-master.sh
Last active January 17, 2024 18:39
Checkout master, pull, checkout previous current branch, merge master into it.
#!/bin/bash
# Save the current branch name
current_branch=$(git rev-parse --abbrev-ref HEAD)
if [ $? -ne 0 ]; then
echo "Error: Failed to get the current branch name."
exit 1
fi
# Set target branch to 'master' or the provided argument
@ierceg
ierceg / .zshrc
Last active August 8, 2024 19:25
macOS + zshell: say "The deployment has finished" after every command that has the string `deploy` in it
# Put this into your .zhrc
DEPLOY_FLAG=0
# Override the 'preexec' function to intercept commands before they are executed
function preexec() {
# Get the command as input
local command="$1"
# Set the flag if the command contains "deploy"