This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#! /usr/bin/env sh | |
# When battery has less than 25%, pops up notifier counting down integer % of battery left 24, 23, 22, 21 ... | |
# When battery is less than 15% also announces "Low Battery" verbal warning. | |
# INSTALL: Put this powerchange.sh file in /Users/Shared/ folder on your mac laptop, then chmod a+x *.sh | |
# And put com.me.powerchange.plist (below) in ~/Library/LaunchAgents/ (or /Library/LaunchAgents/ for every user). | |
# This file is run by com.me.powerchange.plist whenever charger is disconnected | |
# When charger is unplugged, the date of this file changes: Library/Preferences/com.apple.powerlogd.plist | |
## https://stackoverflow.com/questions/14108471/launchd-watchpaths-will-not-trigger-simple-hello-world-script-os-x-10-8 | |
## See also https://github.com/Goles/Battery/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
cd <path to parent folder of the files> | |
echo "Do not open c:\temp\filelist-with-md5.csv until you see current time displayed" | |
filelist /md5 > c:\temp\filelist-with-md5.csv | |
time /t |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/python | |
# encoding: utf-8 | |
# | |
# Copyright 2017 Greg Neagle. | |
# https://github.com/munki/macadmin-scripts/blob/main/installinstallmacos.py | |
# Licensed under the Apache License, Version 2.0 (the "License"); | |
# you may not use this file except in compliance with the License. | |
# You may obtain a copy of the License at | |
# | |
# http://www.apache.org/licenses/LICENSE-2.0 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
sudo defaults write /Library/Preferences/com.apple.RemoteManagement VNCAlwaysStartOnConsole -bool true | |
# https://apple.stackexchange.com/questions/342161/macos-mojave-remote-access-login-screen-stuck-on-infinite-loading-spinner |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Unlike ordinary pdf files, portfolio.pdf files cannot be viewed on tablets or phones, and most software that can open them is available only on windows or mac, not on linux (until recently). They really should have a different extension like .pdfp or similar. Google finds lots of folks looking to batch convert portfolios to individual files, as the portfolio breaks *lots* of automated workflows, especially if you upload them to systems that can't handle them. If you try to open them in other viewers, like a link in a browser, you'll see a misleading messages ending in "get adobe reader now!", like: | |
http://dev.datalogics.com/cookbook/portfolios/portfolio-sample.pdf | |
You get that brain-dead message even if you already have adobe-reader. The work-around is to download the pdf then open in some awful adobe-reader or acrobat software (version 10 or newer is needed, I believe). | |
If you have a bunch of such pdfs, this is a place folder for upcoming script to batch convert portfolio pdf files. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
In example scenario below, the "XP" box can also be vista/win7-8-8.1 (maybe even 10), 32 or 64 bit. | |
How to keep XP on minimally on network, but not internet, using network only to update time and push files via scp/sftp. | |
Both old XP and Server are kept safe by closing all ports on XP, and allow that XP computer to connect only to port 37 on a (rfc868 aka "rdate") time-server. The device providing TIME service on port37 should get its own time from internet/intranet (by ntp, etc). | |
(The time-server does not have run a server-os: it can be almost any linux device, or even a windows-pc.) | |
With all ports closed on XP, the time-server cannot infect XP. If XP is infected, such as by a usb-key, it cannot spread over | |
network to time-server (unless time-server has vulnerability known to virus. Turn off smb1 on time-server (if windows)! | |
On XP/7/8/8.1, rdatesvc.exe (= prdatesvc = PermaSoft Rdate service) safely keeps system time and date correct by periodically from | |
port 37 on a specified time SerVeR, such time.nist.go |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class Python < Formula | |
desc "Interpreted, interactive, object-oriented programming language" | |
homepage "https://www.python.org/" | |
url "https://www.python.org/ftp/python/3.6.9/Python-3.6.9.tar.xz" | |
sha256 "5e2f5f554e3f8f7f0296f7e73d8600c4e9acbaee6b2555b83206edf5153870da" | |
revision 1 | |
bottle do | |
sha256 "1bc5a2d3f0a8602bf2f46de7c43fcb6dde4f110c0f4518d4e802cb1f733a43de" => :high_sierra | |
sha256 "131d39120ac6ca2f21bf231de7414c08916cea472bc5219e0bcb49541f77cb9f" => :sierra |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
if [ $# -eq 0 ] | |
then | |
bnam=$(basename "$0") | |
echo "Usage: $bnam *.csv (displays how many rows & cols, and shows first 2 rows of csv file(s))"; exit | |
fi | |
# EXAMPLE OUTPUT | |
# Total Rows Words Size = 76 76 5587 foobar.csv | |
# Line 1 has 20 Cols = MW,HBA,HBD,N,O,LOGP,ROTB,TPSA,LOGD,RINGS,ARRINGS,HETRINGS,SYSRINGS,SYSRR,FSP3,NSTEREO,ASA,RELPSA,TC,VWSA | |
# Line 2 has 20 Cols = 391.43,6,0,4.54,4,71.33,3.22,4,2,4,4,2,2,2,0.27,1,576.35,0.13,-1,538.32 |