Skip to content

Instantly share code, notes, and snippets.

View madhead's full-sized avatar
😐

madhead

😐
View GitHub Profile
@madhead
madhead / Cura.FCMacro
Last active April 3, 2024 08:11
FreeCAD × Cura × Flatpak integration
# -*- coding: utf-8 -*-
import FreeCAD
import Mesh
import MeshPartGui, FreeCADGui
import MeshPart
import Mesh, Part, PartGui
import uuid
import subprocess
@Envek
Envek / extension.js
Created November 22, 2021 17:50
GNOME Shell extension to switch between two most recently used keyboard layouts
// Installation:
// 1. mkdir -p ~/.local/share/gnome-shell/extensions/switch-to-last-keyboard-layout@envek
// 2. cp ./extension.js ./metadata.json ~/.local/share/gnome-shell/extensions/switch-to-last-keyboard-layout@envek
// 3. Restart GNOME Shell (e.g. log out and log in)
// 4. Enable it in the GNOME Extensions App
// Usage:
// gdbus call --session --dest org.gnome.Shell --object-path /org/gnome/Shell/Extensions/SwitchToLastKeyboardLayout --method org.gnome.Shell.Extensions.SwitchToLastKeyboardLayout.Call
const { Gio } = imports.gi;
const { getInputSourceManager } = imports.ui.status.keyboard;
# 1. Open https://link.springer.com/search/page/1?facet-content-type=%22Book%22&package=mat-covid19_textbooks
# 2. Click on the button on the top right of the table to save results into CSV file (SearchResults.csv)
# 3. Run: python springer.py SearchResults.csv
# Note: Python 3 is needed, `pip install requests` if the module is missing
import sys
import csv
import requests
from pathlib import Path
from os import path
@ren6
ren6 / app_store_receipt_example.json
Created October 15, 2019 12:57
Example of App Store receipt with 2 auto-renewable transactions (trial and renewal)
{
"status": 0,
"environment": "Sandbox",
"receipt": {
"receipt_type": "ProductionSandbox",
"adam_id": 0,
"app_item_id": 0,
"bundle_id": "com.apphud.subscriptionstest",
"application_version": "1",
"download_id": 0,
@cheungnj
cheungnj / script.sh
Last active March 6, 2024 02:35
Convert asciidoc to Github Flavored Markdown
# Adapted from https://tinyapps.org/blog/nix/201701240700_convert_asciidoc_to_markdown.html
# Using asciidoctor 1.5.6.1 and pandoc 2.0.0.1
# Install pandoc and asciidoctor
$ sudo apt install asciidoctor
$ sudo wget https://github.com/jgm/pandoc/releases/download/2.0.0.1/pandoc-2.0.0.1-1-amd64.deb
$ sudo dpkg -i pandoc-2.0.0.1-1-amd64.deb
# Convert asciidoc to docbook using asciidoctor
@danilvalov
danilvalov / config.yml
Last active March 23, 2024 19:47
FlexGet: Автоматическая RSS-скачка сериалов Lostfilm.tv для новой версии сайта
templates:
global:
transmission:
host: xxxxxxxxxxxx
port: xxxx
username: xxxxxxx
password: xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
tvshows:
set:
@leonardofed
leonardofed / README.md
Last active May 3, 2024 01:24
A curated list of AWS resources to prepare for the AWS Certifications


A curated list of AWS resources to prepare for the AWS Certifications

A curated list of awesome AWS resources you need to prepare for the all 5 AWS Certifications. This gist will include: open source repos, blogs & blogposts, ebooks, PDF, whitepapers, video courses, free lecture, slides, sample test and many other resources.


@judoole
judoole / .gitignore
Created April 14, 2016 07:23
gitignore IntelliJ share runConfigurations
.idea/*
!.idea/runConfigurations/