All Questions
24
questions
10
votes
2
answers
1k
views
Wi-fi scheduler written in C
I'm new to C and programming in general (some minimal prior exposure to JS and python). This is also my first time working with shell commands, scripts, and cron. This program works on my macOS and ...
8
votes
2
answers
1k
views
realpath substitute with --relative-to and --relative-base support
In a bash 3 script for OSX machines, I needed the functional equivalent of the realpath command, complete with support for the ...
2
votes
0
answers
22
views
bash script to delete files resurrected by Adobe InDesign bug
After a March update, Adobe Indesign will resurrect removed directories it was responsible for creating in the first place, but not any files except for one file called "AdobeFnt.lst". So where once ...
2
votes
0
answers
43
views
Bash script to scp specific, most-recent files from remote server
I'm writing a helper script that I wish to be able to share with my co-workers. We all work using macOS Mojave, but all have their own shell configurations. For example, I actually use ZSH and bash 5....
2
votes
0
answers
27
views
Auto re-connecting to a VPN on OS X and pointing Squid accordingly
We need to tunnel certain applications over a VPN at work. Ideally we would use a dedicated firewall/network appliance for this but the only permanent infrastructure we have are Mac Pro's running ...
3
votes
1
answer
111
views
Batch rename files recursively, and number the directory index
When dealing with iOS app bundle, It is not convenient to get the file by its path, but loading it by its name.
Need to batch rename images recursively, with Mac Bash. And to make the name unique, ...
3
votes
1
answer
41
views
Batch rename files with Mac Bash,while the dir index should be recorded
I need to batch rename images with Mac Bash,while the directory index should be recorded.
To rename files ,turn
...
1
vote
1
answer
31
views
Mac Bash: how to combine the open and str subtract to one line code? [closed]
new to bash , I use the following code to open the super folder with a file path.
function openUp(){
cd $(echo $1 | sed 's@\(.*\)/.*@\1@' );
open ..
}
like ...
4
votes
0
answers
105
views
appleseed command line widget (CLW)
─── appleseed on GitHub
appleseed v1.0.0 is a command line widget (CLW), I designed for macOS
and iTerm2. Its a flexible platform for process automation and added
eye candy. It utilizes ...
2
votes
1
answer
89
views
Check SMART status on MacOS and pop up alert
So I don't know much about bash scripting. I am just a beginner. I made this script which checks the SMART status of my root volume and if it is failing then it immediately throws a pop up alert if ...
3
votes
2
answers
80
views
Password string generation
I'm trying to create passwords using the following snippet to match a custom password policy. I've added three gtr statements, at the end of the string, to ...
8
votes
1
answer
92
views
Spoofs MAC Address to manufacturer of user's choice, Linux or MacOS
I've made a BASh script for Linux/MacOS that allows you to search for a MAC manufacturer and then generates a MAC address from that company and then spoofs it to that using ...
7
votes
2
answers
280
views
Script to temporarily drop admin privileges
Description
The aim of my project is to allow administrators to drop privileges for reasons of self-control. Currently, it works only on MacOS Sierra but the concept should be extensible to any Unix ...
4
votes
2
answers
69
views
Create and open a file to take lecture notes depending on day and time
I am just wondering what, if any, more elegant ways might exist to write a script to accomplish the task that the script below accomplishes. The script works, so I don't need it to be debugged, but I ...
5
votes
1
answer
154
views
Bash manual page selection menu (version 3)
This is an interactive script for selecting and reading the manual pages from the terminal command line. This is the 3rd version of this script. If you want to see the evolution of this script, follow ...