How can I impose consequences when PCs commit severe crimes?

For context, this is my first adventure as a DM. The PCs are level 2.

About 40 minutes into the first session, while investigating the rumours about a ghost ship, the group meets with Aleyd Burrows, a skilled veteran, Captain of the Guard and a very important figure.

She gives them various pieces of information and sends them on their way with new leads. As the party starts to leave, the last player walks up to Aleyd, shakes her hand and tries to steal her purse. Luckily he passes the Sleight of Hand check with ease since he rolled a 16+8 (he’s a rogue with Expertise). (I chose a DC of 20 without disadvantage: Aleyd is usually quite alert, but the player did make a very natural “Thank you”+handshake, and Aleyd didn’t have a reason to be more alert then usual.)

However, I do not know how to deal with this had he failed.

Knowing him, he is likely going to pull similar stunts.

P.S. I did talk with him afterwards, and he promised to be more mindful from now on.

He enjoys fooling around, but he is trying to do so without reducing the fun of the others.

He also set off a bit of a conflict with another thing he did, which me and the other players commented on. He did thoroughly apologise for it, and they spent some more time talking it out.

I mostly want to know how to deal with deal with such situations without stepping out of the “in game” position.

Stash/BitBucked prevent use from commiting if commit does not include JIRA number

I’m not going to get a working solution but at least to get an answer if it is possible at all by Stash/Bitbucket. So my request is: We need to deploy some policy for ourselves in the company not to allow engineer to commit if commit comment does not contain (best does not begin with) JIRA issue number. For instance:

TEST-1234 (Jira under which I'm doing a commit) Here's my code 

Thank you in advance!

Different commit messages depending on which machine I commit from

I’m using eclipse to write java programs. Currently I use my desktop to program at home, and a laptop when I am in school. For version control I use git. When committing using eGit in eclipse, it uses the same commit message / sign off when committing from my laptop and desktop. Is there a way I can automatically make it include a tag or something similar that includes what machine I am committing from? Right now it only includes author: email and name, which of course are the same for my laptop and desktop. I would really like to be able to track whether I used my laptop or desktop. Thanks

Hacer un SavePoint, Rollback y Commit de Oracle en django, (Python 1.8.7)

Quisiera hacer un savepoint, un rollback y un commit de Oracle en una view. Por ejemplo

def ejemploview(request):   if request.method =='POST':     with connection.cursor() as cursor:       #Aqui quisiera hacer el equivalente a savepoint save; en Oracle       ...       ...       if i>0:        #Aqui quisiera hacer el equivalente a rollback save; en Oracle        #Aqui quisiera hacer el equivalente a commit; en Oracle       else:         #Aqui quisiera hacer el equivalente a commit; en Oracle 

Me preguntaba si existia algo como el cursor.execute() para estos casos

Tem como deixar um commit somente local?

A pergunta pode ser meio obvia ou até mesmo confusa. Mas o que eu quero saber é se tem como deixar um commit somente local, por exemplo. Eu estou trabalhando em um funcionalidade e tal, fiz alguns commits importantes, mas de repente vem uma demanda urgente, que preciso concluir e enviar pro servidor. Como faço para enviar apenas o que foi solicitados(Como se eu escolhesse os commits a ser enviados e deixasse os que estava trabalhando antes).

Estou iniciando com git.

bash wrapper around ‘git commit’ to automatically bump (Python) package CalVer and create matching CalVer tag on new commit

I’m doing a lot of Python development lately for various (small-)data analysis pipelines at work. I’ve been wrestling with how to robustly and ~automatically version the code at a fine-grained level, so as to provide strong guarantees of reproducibility of a result generated from any particular version of the code, at any particular point in my development process.

I’ve settled on a CalVer approach. Given that I often want to have multiple versions of the code tagged within a single day, I’m using a ~nonstandard $ TIMESTAMP format of YYYY.MM.DD.hhmm. (hhmmss seemed like it would be overkill.)

In any event, I want two things to happen every time I commit code to one of these data analysis repos:

  1. Wherever relevant in the package (usually just in the main, __version__ should be updated to $ TIMESTAMP.
  2. Once the code is committed, a tag named $ TIMESTAMP should be applied to the new commit

Ancillary goals are the usual: easy to configure, minimal likelihood of breaking all the things, and minimal additional cleanup effort in common non-happy-path scenarios.

The following is a bash script I’ve put together for the purpose:

#! /bin/bash  export TIMESTAMP="$  ( date '+%Y.%m.%d.%H%M' )" export VERPATH='.verpath'  if [ -z $  VERPATH ] then   # Complain and exit   echo "ERROR: Path to files with versions to update must be provided in {repo root}/.verpath"   echo " "   exit 1 fi  # $  VERPATH must contain the paths to the files to be updated with # the timestamped version, one per line while read VERFILE do   # Cosmetic   echo ""    if [ -e "$  VERFILE" ]   then     # File to be updated with version exists; update and add to commit.     # Tempfile with old file stored in case of commit cancellation.     echo "Updating $  VERFILE"     cp "$  VERFILE" "$  VERFILE.tmp"     sed -i "s/^__version__ = .*$  /__version__ = '$  TIMESTAMP'/" $  VERFILE     git add "$  VERFILE"    else     echo "$  VERFILE not found!"    fi  done < $  VERPATH  # Cosmetic echo ""  # So user can see what was updated sleep 2s  # Actually do the commit, passing through any parameters git commit $  @  # If the commit succeeded, tag HEAD with $  TIMESTAMP and delete temp file(s). # If the commit failed, restore the prior state of the $  VERFILEs. if [ "$  ?" -eq "0" ] then   git tag -f "$  TIMESTAMP"    while read VERFILE   do     rm -f "$  VERFILE.tmp"   done < $  VERPATH  else   while read VERFILE   do     if [ -e "$  VERFILE.tmp" ]     then       git reset HEAD "$  VERFILE" > /dev/null 2>&1       rm "$  VERFILE"       mv "$  VERFILE.tmp" "$  VERFILE"     fi   done < $  VERPATH  fi 

The contents of .verpath in my test repo are:

pkg/ pkg/ pkg/ 

Both pkg/ and pkg/ exist; pkg/ does not.

I have *.tmp in my .gitignore so that the $ VERFILE.tmp don’t show up as untracked files when drafting the commit message.

It works like I want it to… the happy path works great, and it handles aborted commits and nonexistent .verpath files gracefully.

I’m no bash expert, though, so I’m partly concerned about subtle misbehaviors I haven’t thought of. Also, I’m not super thrilled about the use of in-folder temporary files, and per here and here the while read VERFILE ... done < $ VERPATH has the potential to be fragile if I don’t set it up correctly.

How to make a commit when not the original author?

I’m attempting to push a repository on a project that I didn’t originally write and and it seems as though git is asking me for the original authors password and getting rejected:

projectname darrinwebster$ git push origin master

Password for ‘’:

remote: Invalid username or password

fatal: Authentication failed for ‘’

How do I go about making the project mine so that I can push to a repository under my own account if that makes sense? I’ve tried abunch of things including deleting everything git related in keychain access and just logining in again in terminal but nothing is working.

How to delete all the commit history of a specific folder in Git

I am working on a project. Accidentally, I copied really large video files into a folder called ‘project/files’ folder. Then I committed them and pushed it to my branch. In the next commit, I just deleted them all and pushed it again. Then I merged them into master branch. The problem is that since they are still in the commit history, when I pull my master branch, it is taking ages because git is trying to pull them again from the history. So, I am having the problem during the deployment as well. What I like to do is that to solve that problem, I like delete all the commit history of this folder ‘project/files’. How can I do that? Or what is the other solution around, please? I seriously need to remove them from the history.