Skip to content

Instantly share code, notes, and snippets.

View gcakir's full-sized avatar
🤔

Göksenin Cakir gcakir

🤔
  • Göttingen, Germany
View GitHub Profile
@denisgolius
denisgolius / generate-ssh-key.sh
Created October 4, 2018 06:55 — forked from grenade/01-generate-ed25519-ssh-key.sh
Correct file permissions for ssh keys and config.
ssh-keygen -t rsa -b 4096 -N '' -C "rthijssen@gmail.com" -f ~/.ssh/id_rsa
ssh-keygen -t rsa -b 4096 -N '' -C "rthijssen@gmail.com" -f ~/.ssh/github_rsa
ssh-keygen -t rsa -b 4096 -N '' -C "rthijssen@gmail.com" -f ~/.ssh/mozilla_rsa
@paolocarrasco
paolocarrasco / README.md
Last active May 3, 2024 15:20
How to understand the `gpg failed to sign the data` problem in git

Problem

You have installed GPG, then tried to commit and suddenly you see this error message after it:

error: gpg failed to sign the data
fatal: failed to write commit object

Debug

@source-nerd
source-nerd / Ubuntu 18.04 Docker File
Created May 25, 2018 05:23
Docker Image for Ubuntu 18.04 and Python 3.6
FROM ubuntu:18.04
RUN apt-get update
RUN apt-get install -y build-essential
# This will install Python, pip, pip3, and pip3.6.
RUN curl https://bootstrap.pypa.io/ez_setup.py -o - | python3.6 && python3.6 -m easy_install pip
RUN apt-get update
RUN apt-get install -y python3.6-venv
@PHPirates
PHPirates / git-bundles.md
Last active March 7, 2023 14:28
How to use git bundles

Let machine M be the Main machine with the repo, and A the Auxiliary machine which wants to help out.

First time setup

  1. Machine M creates bundle with complete repo:
git bundle create repo.bundle HEAD master
  1. M sends repo.bundle to A.
  2. A clones repo from bundle:
@TeknoVenus
TeknoVenus / Useful Programs.md
Last active December 1, 2023 16:03
Useful programs

My useful utilities and favourite programs to make everyday life that bit easier

Most of these are Windows based, but some are cross-platform. They are mainly free tools, but paid ones have been marked accordingly. Freemium tools have a free version but have a full version for a price. Tools are in no particular order

Utilities

@lee-pai-long
lee-pai-long / caller_info.py
Last active March 20, 2024 16:42 — forked from techtonik/caller_name.py
Python - inspect - Get full caller info: package, module, (class), function, line.
"""
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
Version 2, December 2004
Copyright (C) 2004 Sam Hocevar <sam@hocevar.net>
Everyone is permitted to copy and distribute verbatim or modified
copies of this license document, and changing it is allowed as long
as the name is changed.
@ultim8k
ultim8k / vim-multiline-comment.md
Last active April 30, 2024 18:46
(un) comment multiple lines vim

From: http://stackoverflow.com/questions/1676632/whats-a-quick-way-to-comment-uncomment-lines-in-vim

For those tasks I use most of the time block selection.

Put your cursor on the first # character, press Ctrl``V (or Ctrl``Q for gVim), and go down until the last commented line and press x, that will delete all the # characters vertically.

For commenting a block of text is almost the same: First, go to the first line you want to comment, press Ctrl``V, and select until the last line. Second, press Shift``I``#``Esc (then give it a second), and it will insert a # character on all selected lines. For the stripped-down version of vim shipped with debian/ubuntu by default, type : s/^/# in the second step instead.

@Zearin
Zearin / python_decorator_guide.md
Last active March 30, 2024 12:28
The best explanation of Python decorators I’ve ever seen. (An archived answer from StackOverflow.)

NOTE: This is a question I found on StackOverflow which I’ve archived here, because the answer is so effing phenomenal.


Q: How can I make a chain of function decorators in Python?


If you are not into long explanations, see [Paolo Bergantino’s answer][2].

// XPath CheatSheet
// To test XPath in your Chrome Debugger: $x('/html/body')
// http://www.jittuu.com/2012/2/14/Testing-XPath-In-Chrome/
// 0. XPath Examples.
// More: http://xpath.alephzarro.com/content/cheatsheet.html
'//hr[@class="edge" and position()=1]' // every first hr of 'edge' class