git
selene tan

Tag: git

PR Queue Checker

by on Oct.26, 2018, under Portfolio

At ThinkNear, every commit must be reviewed before it is merged into the master branch. To do this, the submitter opens a pull request (PR) on GitHub, and assigns it to one of the code reviewers for that project. Reviewers ran into problems where one developer might be flooded with PRs while another had nothing, and where it was hard to stay on top of PRs from five or more different repositories. In 2015, I created the pull request checker tool to solve both problems, and have maintained it since then.

The PR Queue Checker takes a GitHub organization name, username, and a Github Personal Access Token. It uses these to query the GitHub API for open PRs among that organization’s repositories, and displays them in a formatted list. The code is in a single HTML file that uses the jQuery and lodash libraries, allowing you to save the HTML file and load it locally.

PR Queue Checker

GitHub

 

 

 

Leave a Comment :, , , full post

Git on Dreamhost

by on Oct.14, 2009, under Blog

Though my website is hosted on Dreamhost, these days I mostly use them for version control hosting. So I was very happy when they set up git on their servers.

Casper Fabricius’ Keeping git repositories on Dreamhost using SSH has some instructions and a handy script for automating the process. Thing is, I tend to create the folders and files for a project before I set up the git repository. Casper’s script assumes you want to create the folder and repository at the same time.

So here’s my version of the script. If you call it without arguments, it assumes you want to make a repository for the current directory.

DREAMGIT_DOMAIN=user@yourdomain.com
if [ $# -lt 1 ]; then
  PROJECT_DIR=${PWD##*/}
else
  PROJECT_DIR=$1
  mkdir $PROJECT_DIR
  cd $PROJECT_DIR
fi
ssh $DREAMGIT_DOMAIN 'mkdir -p ~/git/'$PROJECT_DIR'.git && cd ~/git/'$PROJECT_DIR'.git && git --bare init'
git init
git remote add origin ssh://$DREAMGIT_DOMAIN/~/git/$PROJECT_DIR.git
touch .gitignore
git add .
git commit -m 'Created new repo'
git push origin master
echo "
[branch \"master\"]
remote = origin
merge = refs/heads/master" >>.git/config
echo "Your new git repo '$PROJECT_DIR' is ready and initialized at
$DREAMGIT_DOMAIN/~/git/$PROJECT_DIR.git"

Note: both Casper’s and my scripts still work if you call them with a directory that exists, e.g. dreamgit dir_that_exists. You’ll see mkdir spout an error, but the rest will execute.

2 Comments :, , full post

Looking for something?

Use the form below to search the site:

Still not finding what you're looking for? Drop a comment on a post or contact us so we can take care of it!