Skip to content

Instantly share code, notes, and snippets.

View txoof's full-sized avatar

Aaron Ciuffo txoof

View GitHub Profile
@txoof
txoof / pdf_rmN.md
Last active April 6, 2024 15:27
PDF to Editable Remarkable Notebook (Mac OS)

Converting a PDF to an editable reMarkable Notebook

Use case: Working with PDF text books, it can be helpful to be able to extract problems and images to use in notes and when working problemsets on the reMarkable tablet.

These instructions are MacOS centric, but should be reproducable on most platforms as the tools are fairly platform agnostic.

Requirements

  • homebrew - package manager for installing components
  • DrawJ2d - Convert PDF to remarkable notebook (rmn) format
@txoof
txoof / spocon.md
Last active April 10, 2024 17:32
Install SpoCon on BookWorm and Later if Installer Fails

Installer Failure Modes

Failure: Unmet Dependendencies

Open JDK 8, 11 are unavailable for Bookworm and later

The following packages have unmet dependencies:
 spocon : Depends: openjdk-11-jre but it is not installable or
                   openjdk-8-jre but it is not installable
@txoof
txoof / PowerQuery_Notes.md
Last active February 28, 2024 19:24
Guide for things that can and should not be done when creating power queries.

PowerQuery Creation Notes

Notes

Returned Column References

The columns section of the XML document refer to the columsn that will be offered in the Data Export Manager screens. The text of the column name is arbitrary and can be anything, but the <column column="TABLE.FIELD"> portion must referr to a "core" table of powerschool. When in doubt, use column="STUDENTS.ID"

<columns>
@txoof
txoof / PyPi.md
Last active October 30, 2023 19:28
Trusted Publishing to PyPI

Trusted Publishing to PyPI

PyPi no longer allows simple username/password authhentication through twine. 2FA is now required for all publisyhing.

This gist is based on this PyPA guide

Requirements

@txoof
txoof / syncthing setup.md
Last active August 11, 2023 18:42
Set up Syncthing on Linux host for multiple users

Set Up SyncThing on Linux Host for Multiple Users

This covers setting up SyncThing on Ubunty/Debian

Install Syncthing

$ sudo apt-install syncthing

Enable Syncthing for Each User

#!/usr/bin/env python3
# coding: utf-8
# display the time vaugely as a string (The Time is about Ten to Seven); update every 5 minutes
# to adjust the timing use:
# $ word_clock.py -t xx
import os
from datetime import datetime
@txoof
txoof / tunneling.md
Last active December 28, 2023 06:50
Tunnel ssh connections through firewalls

SSH Tunnels

Situation: Local Network Firewall blocks outgoing connections to remote hosts on port 22

In this situation it is not possible to connect to remote hosts (e.g. github.com) for managing repos over ssh. A tunnel through a remote host (tunnel.myhost.com) can remedy this. An ssh configuration file can be added to the ~/.ssh/config directory to specify a specific command for connecting github.com. See also How to setup SSH Tunneling

Setup

  1. create a tunnel host that accepts incomming connections:
    • tunnel.myhost.com
  2. install nc
@txoof
txoof / pyenv_mac_os.md
Last active October 6, 2022 09:04
Setup Python pyenv for Jupyter with nbconvert on Mac OS

If nbconvert throws a similar error, it is likely because the jupyter installation is not setup properly within a pyenv

ValueError: No template sub-directory with name 'python' found in the following paths:
	/Users/aciuffo/Library/Jupyter
	/opt/homebrew/Cellar/python@3.9/3.9.2_1/Frameworks/Python.framework/Versions/3.9/share/jupyter
	/usr/local/share/jupyter
	/usr/share/jupyter
@txoof
txoof / Setup_gCloud_SSH.md
Last active March 7, 2021 12:47
setup ssh on google cloud instance
@txoof
txoof / jupyter.md
Last active November 28, 2020 06:32
Installing Jupyter on Rasbian

Setting up Jupyter on Raspbian for Development

  • Install jupyter:
    • $ pip3 install jupyter
  • launch a Jupyter notebook server that is available over the local network:
    • $ jupyter-notebook --ip=$(hostname -I) --no-browser
$ jupyter-notebook --ip=$(hostname -I) --no-browser
[I 05:51:34.280 NotebookApp] Serving notebooks from local directory: /home/pi
[I 05:51:34.280 NotebookApp] Jupyter Notebook 6.1.5 is running at: