Skip to content

Instantly share code, notes, and snippets.

{ pkgs ? import <nixpkgs> {} }:
let
poetry2nix = import (pkgs.fetchFromGitHub {
owner = "nix-community";
repo = "poetry2nix";
rev = "2024.2.2230616"; # Specify a specific commit hash or tag
sha256 = "sha256-3Kq2l6xedw2BkvcASyAzNyjYRvupNiKxUvnBfcqOomM="; # The hash of the source for integrity verification
}) { inherit pkgs; };
@paradx
paradx / create Diff PDF
Last active October 23, 2017 06:14
Same as CreatePDF Gist but will use git-latexdiff to also create a diff PDF version. Need Git and git-latexdiff to work (https://github.com/redreamality/git-latexdiff and https://git-scm.com/download )
taskkill /im AcroRd32.exe
echo "$(CURRENT_DIRECTORY)"
cd "$(CURRENT_DIRECTORY)"
npp_save
git latexdiff --biber --type=CCHANGEBAR --output diff.pdf --main "$(FILE_NAME)" HEAD --
pdflatex.exe "$(FILE_NAME)"
biber.exe "$(NAME_PART)"
pdflatex.exe "$(FILE_NAME)"
pdflatex.exe "$(FILE_NAME)"
cmd /C start "AdobeAcrobat" /D C:\Progra~2\Adobe\ACROBA~1\Reader\ Acrord32.exe $(CURRENT_DIRECTORY)\diff.pdf
@paradx
paradx / createPDF
Created October 23, 2017 06:11
NppExec Script for compiling latex with biber and starting the pdf reader (in this case Adobe Acrobat). To prevent r/w issues on the opened files, the PDF viewer will be closed.
taskkill /im AcroRd32.exe
npp_save
cd "$(CURRENT_DIRECTORY)"
pdflatex.exe "$(FILE_NAME)"
biber.exe "$(NAME_PART)"
pdflatex.exe "$(FILE_NAME)"
pdflatex.exe "$(FILE_NAME)"
cmd /C start "AdobeAcrobat" /D C:\Progra~2\Adobe\ACROBA~1\Reader\ Acrord32.exe $(CURRENT_DIRECTORY)\$(NAME_PART).pdf
@paradx
paradx / riskmgmmatrix.tex
Created June 7, 2017 08:08
Riskmanagement Matrix to plot risks in a grid of consequences of occurence
\usepackage{tikz} %the package that allows all the magic
%document start etc...
\begin{figure}[h]
\begin{tikzpicture}
[every node/.style=
{minimum width=3.95 cm, %each field is about 4 cm wide
minimum height= 1.95cm, %each field is about 2 cm high