Archive

For July, 2016

Parametric Screw to Zip Tie Adapter

No Comments

A ‚ÄúParametric Screw to Zip Tie Adapter” is now available. More details at Parametric Screw to Zip Tie Adapter .

Customizable Small Linear Carriage

No Comments

A ‚ÄúCustomizable Small Linear Carriage Generator” is now available. More details at Customizable Small Linear Carriage .

Script to create a shared git project

No Comments

This script creates a git project to be shared among the users of the Unix group $GIT_GROUP. Every git project will be created into the directory $REPOSITORIES_BASE_DIR.

#!/bin/bash

# Base directory where the shared git project are.
REPOSITORIES_BASE_DIR="/home/git"
# Group in which the user's of the repositories must be a member of
GIT_GROUP=git

if [ $# -ne 1 ]; then
        echo 'Usage:' `basename $0` 'project-name'
        exit 1
fi

PROJECT_NAME=$1

cd "$REPOSITORIES_BASE_DIR"
git init --shared --bare "$PROJECT_NAME"
cd ..
find git/$PROJECT_NAME -type d | xargs setfacl -R -m d:g:$GIT_GROUP:rwX
sudo setfacl -R -m g:$GIT_GROUP:rwX git/$PROJECT_NAME
Blue Taste Theme created by Jabox