Skip to content

Instantly share code, notes, and snippets.

Fred Barclay Fred-Barclay

  • Bumping around in the bush.
View GitHub Profile
@Fred-Barclay
Fred-Barclay / get_last_commit.py
Created Jan 15, 2019
Find the checksum of the most recent commit in a GitHub repository
View get_last_commit.py
#!/usr/bin/env python3
"""
Get the sha sum of the last commit on the master branch
of a github repository.
Suitable for using in shell scripts: i.e.
last_commit=`python3 ~/bin/get_last_commit.py $url` will
assign the sha sum of the last commit found at $url
to $last_commit. In this case (for bash at least)
print(shasum) will not actually print the sha sum to the
View brave.prfile
# Firejail profile for brave
# This file is overwritten after every install/update
# Description: Web browser that blocks ads and trackers by default.
# Persistent local customizations
include brave.local
# Persistent global definitions
include globals.local
noblacklist ${HOME}/.config/brave
noblacklist ${HOME}/.config/BraveSoftware
@Fred-Barclay
Fred-Barclay / gist:c55529dc47075a1e4cb4e08a5dc46dce
Created Sep 30, 2018
LMDE 3 all potential packages from deb-multimedia
View gist:c55529dc47075a1e4cb4e08a5dc46dce
/var/lib/apt/lists/www.deb-multimedia.org_dists_stretch_main_binary-amd64_Packages:Package: 2mandvd
/var/lib/apt/lists/www.deb-multimedia.org_dists_stretch_main_binary-amd64_Packages:Package: 2mandvd-data
/var/lib/apt/lists/www.deb-multimedia.org_dists_stretch_main_binary-amd64_Packages:Package: aacgain
/var/lib/apt/lists/www.deb-multimedia.org_dists_stretch_main_binary-amd64_Packages:Package: aacplusenc
/var/lib/apt/lists/www.deb-multimedia.org_dists_stretch_main_binary-amd64_Packages:Package: aacskeys
/var/lib/apt/lists/www.deb-multimedia.org_dists_stretch_main_binary-amd64_Packages:Package: acoustid-fingerprinter
/var/lib/apt/lists/www.deb-multimedia.org_dists_stretch_main_binary-amd64_Packages:Package: acroread-debian-files
/var/lib/apt/lists/www.deb-multimedia.org_dists_stretch_main_binary-amd64_Packages:Package: acroread-fonts-jpn
/var/lib/apt/lists/www.deb-multimedia.org_dists_stretch_main_binary-amd64_Packages:Package: advancemenu
/var/lib/apt/lists/www.deb-multimedia.org_dists_stretch_main_binary-amd
@Fred-Barclay
Fred-Barclay / gist:2f09a203341dd97d2b23651e5f4af251
Created Sep 30, 2018
LMDE 3 packages from deb-multimedia
View gist:2f09a203341dd97d2b23651e5f4af251
ii libasound2-plugins:amd64 1:1.1.4-dmo1 amd64 ALSA library additional plugins
ii libavcodec57:amd64 10:3.3.8-dmo1+deb9u1 amd64 Library to encode decode multimedia streams - runtime files
ii libavformat57:amd64 10:3.3.8-dmo1+deb9u1 amd64 FFmpeg file format library
ii libavutil55:amd64 10:3.3.8-dmo1+deb9u1 amd64 FFmpeg avutil library - runtime files
ii libbabl-0.1-0:amd64 1:0.1.28-dmo1 amd64 Dynamic, any to any, pixel format conversion library
ii libbluray2:amd64 2:1.0.0-dmo1 amd64 Blu-ray disc playback support library (shared library)
ii libchromaprint1:amd64 1:1.4.2-dmo1 amd64 Audio fingerprint library
ii libfdk-aac1:amd64 1:0.1.5-dmo2 amd64 Fraunhofer FDK AAC co
View wireless-info
#!/bin/bash
#
# Copyright (c) 2012
#
# Authors: Wild Man, Krytarik
# Helpers: chili555
#
# This script gathers the infos necessary for troubleshooting a wireless
# connection and saves them in a text file, wrapping it in an archive if it
# exceeds the 19.5 kB size limit for ".txt" attachments on the Ubuntu Forums.
View wireless.sh
wget -N -t 5 -T 10 https://github.com/UbuntuForums/wireless-info/raw/master/wireless-info && \
chmod +x wireless-info && \
./wireless-info
View fs_lib.c
/*
* Copyright (C) 2017 Firejail Authors
*
* This file is part of firejail project
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
View GetDistanceUnstable.m
function [ distance ] = GetDistanceUnstable( subPT, vertPT, deg_Increment )
% Code originally written by Skylar Gay
% and W. Scott Ingram at the University
% of Texas M. D. Anderson Cancer
% Center, Houston, Texas. All copies of
% this code, even if modified, must
% contain this message.
% No warranty or fitness for duty is
% expressed or implied by the authors.
View GetDistanceTesting.m
function [ distance ] = GetDistanceTesting( subPT, vertPT, deg_Increment )
%UNTITLED2 Summary of this function goes here
% Detailed explanation goes here
tic
theta=(0:deg_Increment:(360-deg_Increment));
%Sets the value of theta from 0 degrees to the largest angle that is not
%coterminal with 0 degrees and <360 degrees.
numVert=(numel(vertPT))/2;
View gufw
fred@lmde-beta ~ $ gufw
(gufw.py:4006): Gtk-CRITICAL **: gtk_list_store_iter_next: assertion 'priv->stamp == iter->stamp' failed
(gufw.py:4006): Gtk-CRITICAL **: /home/clem/Sandbox/gtk/./gtk/gtktreeview.c:5495 (gtk_tree_view_bin_draw): assertion `has_next' failed.
There is a disparity between the internal view of the GtkTreeView,
and the GtkTreeModel. This generally means that the model has changed
without letting the view know. Any display from now on is likely to
be incorrect.
You can’t perform that action at this time.