Screen capture with audio from Linux
Screen capture with audio is simple, cross-platform and stable using OBS Studio. We no longer use FFmpeg due to current lack of Wayland support, and extensive command line options needed regardless of OS.
Screen capture with audio is simple, cross-platform and stable using OBS Studio. We no longer use FFmpeg due to current lack of Wayland support, and extensive command line options needed regardless of OS.
Upon forking another project’s repository to make contributions, one might have enabled GitHub Actions for the fork. If there are scheduled actions, then GitHub Actions will keep running on the forked repository, which can consume resources and is probably not desired. The simplest solution is to disable GitHub Actions for the forked repository, which is done from the URL of this form:
https://github.com/<your-username>/<forked-repo-name>/settings/actions
CMake can tell the default generator for the current platform without configuring a project. This is useful for build scripts that want to detect the generator default for CMake without having to configure a project first.
On Unix-like platforms, the default generator is typically “Unix Makefiles”. On Windows, the default generator is the latest Visual Studio version installed on the system and supported by CMake. With MSYS2 on Windows, the default generator is “MinGW Makefiles”.
Determine the default CMake generator on Unix-like platforms:
cmake --system-information | awk '/^CMAKE_GENERATOR / {print substr($0, index($0,$2))}'Determine the default CMake generator with PowerShell:
cmake --system-information | Select-String '^CMAKE_GENERATOR ' | % { ($_ -split '^CMAKE_GENERATOR\s+', 2)[1] }If the environment doesn’t have a C or C++ compiler available, CMake might fail to determine the default generator. A missing compiler would likely only be an issue on Windows or minimal Linux / macOS / Unix environments.
On Unix-like platforms, there may be a working directory named “__cmake_systeminformation” created by CMake when running the above command. This directory can be deleted. To avoid using the current working directory on Unix-like platforms, run the above command in a temporary directory:
( cd "$(mktemp -d)" && cmake --system-information | awk '/^CMAKE_GENERATOR / {print substr($0, index($0,$2))}' )A platform-independent, self-cleaning temporary directory can be used with Python:
import subprocess
import tempfile
with tempfile.TemporaryDirectory(ignore_cleanup_errors=True, delete=True) as temp_dir:
result = subprocess.check_output(
['cmake', '--system-information'],
cwd=temp_dir,
text=True
)
for line in result.splitlines():
if line.startswith('CMAKE_GENERATOR '):
default_generator = line.split(' ', 1)[1].strip().strip('"')
print(default_generator)
breakRelated: detect CMake cached generator
From Cygwin, in Octave prompt:
pkg install -verbose cfitsioThis should build and install FITS from C source without errors.
Load the fits package by:
pkg load fitsThis enables Octave FITS read/write functions.
Building CFITSIO manually is not necessary; this is just for reference:
curl -O https://heasarc.gsfc.nasa.gov/FTP/software/fitsio/c/cfitsio_latest.tar.gz
tar -xf cfitsio*.tar.gz
cmake -Bbuild
cmake --build build
ctest --test-dir buildWhile developing a software project, it may be useful to verify the stability of the program or library by denying the ability to execute child processes. This helps ensure the top program is stable in such cases by using an interposer. This technique is demonstrated for Linux, macOS, and Windows on compilers including GCC, Clang, MSVC, NVHPC, and oneAPI. This is not a cybersecurity sandbox, but rather a limited development tool to test stability of the top program when child process launches fails.
Use this interposer demo by:
git clone https://github.com/scivision/interposer-nochild
cd interposer-nochild
cmake --workflow --preset defaultRun the interposer with most other programs by:
build/no-children.exe myprogram.exe arg1 args ...DYLD_INSERT_LIBRARIES=build/libnochild.dylib myprogram arg1 args ...LD_PRELOAD=build/libnochild.so myprogram arg1 args ...Actual sandboxing tools can additionally deny access to resources including filesystem, network, and/or child processes such as:
In Unix-like shells, a
pseudo-file
can be used as input of script for CMake.
CMake can read from a pseudo-file or stdin on the command line, allowing one to run CMake script cmake -P ... commands without creating temporary files.
This method by design is only for CMake script role; it does not work with other
CMake roles
like PROJECT.
Pseudo-file example for Unix-like shells and CMake ≥ 4.2:
cmake -P <(printf '%s\n' 'message("${CMAKE_VERSION}")')stdin standard input example for Unix-like shells across all versions of CMake:
cmake -P /dev/stdin <<< "message('\${CMAKE_VERSION}')"That’s useful to print the CMake version without parsing the output of cmake --version or creating a temporary file with the CMake script.
On Windows in PowerShell or Windows ComSpec, there isn’t a direct equivalent method to use stdin / CONIN$ or a pseudo-file.
Use a temporary file instead, or use WSL to run the above Unix-like shell examples.
There was a previous
attempt to add cmake -P - support for stdin
but as of this writing it was closed without merging.
HDF5 is a popular data container format, a filesystem within a file. Many programs supporting HDF5 like Matlab can read and plot data. It is useful to have a standalone simple data browser like HDFview, which is a Java-based application to view, create, and modify HDF5, netCDF4 and FITS files in a tabular format. HDFView can also make 1-D (line) plots and 2-D (raster) plots of the data in an HDF5 file. For example data see Neon. To view a plot of data, right click on the dataset name and select “Open As” and then set the parameters to view the data.
HDFview enables editing (writing) as well as reading HDF5.
apt install hdfviewbrew install --cask hdfviewViTables is a Python-based HDF5 GUI.
Panoply is available for macOS, Linux and Windows.
For VM server images in particular, the main display of the VM may never activate. The UTM message is like:
display output is not active
This is solved by powering off the VM, and adding a Serial Device under the UTM VM settings. Rebooting will automatically popup a separate windows for the Serial terminal, where boot messages and login can be accomplished. Often the main display window will then start working.

Josh Katz posted his
version of wc
word count utility that was markedly faster than
GNU Coreutils wc.
We haven’t tried benchmarking
uutils Rust-based coreutils
wc that’s used by
Ubuntu.
The Wilson 1000 is a popular high-performance magnet mount antenna for CB radio and 10 meter amateur radio. The screw-on loading coil design may lead to the magnetic base becoming loose from the antenna mount, which can cause high SWR spikes that could damage the transmitter. Eventually, the antenna could detach from the magnetic base and fall off the vehicle, which is a safety hazard. The symptom of this is when the magnetic base is on a metallic surface, gentle twisting of the plastic shroud allows rotation of the shroud over the magnetic base - this is a problem, the shroud should not be able to rotate over the magnetic base when the antenna is properly tightened. This procedure works for similar antennas with a screw-on coil including the Wilson 5000, Stryker SR-A10MM, Radio Shack 21-940A, and others.
The tools required to fix this are a 9/16" socket, a 9/16" wrench, and a 11/16" wrench. An adjustable wrench may be used, but a 9/16" socket is strongly recommended along with whatever wrench is used. Gently peel off the vinyl sheet covering the magnetic base and set it in a clean space as it will be reused. Gently lift off the plastic shroud and slide it down the cable several inches to expose the nut and coax connection to the antenna base. Use the 9/16" socket under the magnetic base and the 9/16" wrench on the nut above the magnetic base to tighten the nut to the magnetic base. Don’t use excessive force as the nut can be stripped or the magnetic base can be damaged. After tightening the nut, slide the plastic shroud back up and tighten the shroud with the 11/16" wrench to secure it to the antenna base. Finally, reapply the vinyl sheet to the magnetic base to protect it from corrosion and to maintain the appearance of the antenna. Be sure not to crinkle the vinyl sheet as this can affect antenna SWR performance and the attachment strength of the magnetic base to the vehicle.