{"id":18974509,"url":"https://github.com/m7a/lo-shellscripts","last_synced_at":"2025-09-14T23:12:12.169Z","repository":{"id":164554614,"uuid":"324444446","full_name":"m7a/lo-shellscripts","owner":"m7a","description":"Standalone and useful shell scripts for Linux","archived":false,"fork":false,"pushed_at":"2024-04-28T19:45:15.000Z","size":40,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-06-02T13:16:53.284Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Shell","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/m7a.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2020-12-25T22:45:23.000Z","updated_at":"2024-04-28T19:45:19.000Z","dependencies_parsed_at":"2024-04-28T20:47:07.946Z","dependency_job_id":null,"html_url":"https://github.com/m7a/lo-shellscripts","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/m7a/lo-shellscripts","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/m7a%2Flo-shellscripts","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/m7a%2Flo-shellscripts/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/m7a%2Flo-shellscripts/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/m7a%2Flo-shellscripts/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/m7a","download_url":"https://codeload.github.com/m7a/lo-shellscripts/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/m7a%2Flo-shellscripts/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":275180222,"owners_count":25419066,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-09-14T02:00:10.474Z","response_time":75,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-08T15:15:16.147Z","updated_at":"2025-09-14T23:12:12.140Z","avatar_url":"https://github.com/m7a.png","language":"Shell","readme":"---\nsection: 32\nx-masysma-name: shellscripts\ntitle: Standalone and useful Shell Scripts for Linux\ndate: 2020/10/26 22:02:08\nlang: en-US\nauthor: [\"Linux-Fan, Ma_Sys.ma (Ma_Sys.ma@web.de)\"]\nkeywords: [\"mdvl\", \"shell\", \"script\", \"linux\", \"virt-manager\"]\nx-masysma-version: 1.0.0\nx-masysma-website: https://masysma.net/32/shellscripts.xhtml\nx-masysma-repository: https://www.github.com/m7a/lo-shellscripts.git\nx-masysma-owned: 1\nx-masysma-copyright: |\n  Copyright (c) 2020 Ma_Sys.ma.\n  For further info send an e-mail to Ma_Sys.ma@web.de.\n---\nOverview\n========\n\nThis repository contains various Ma_Sys.ma shell scripts used with MDVL. They\nare indented to be runnable independently of each other although some synergies\nmay exist (e.g.: `ma_cryptvol` can optionally use `deltamount`).\n\nNon-MDVL-users may find it interesting to use and adapt the individual script\nfiles rather than installing all of them.\n\nThe following scripts are available:\n\n-------------------------------  ------------------------------------------------------------------\n`boxes`                          Display boxes of text characters in the terminal.\n`deltamount`                     Create a bind-mountpoint where changes go to a separate directory.\n`find_double_windows_filenames`  Detect names which only differ wrt. uppercase/lowercase.\n`gimp_convert_to_indexed`        Batch-convert `.tga` files to indexed `.png` files.\n`ma_cryptvol`                    Mount and umount encrypted volumes.\n`ma_rename_normalize`            Recursively rename files.\n`ma_scrmir`                      Invoke `xrandr` to mirror screen to beamer.\n`ma_vnc_over_ssh`                Connect to remote system by VNC tunnelled through ssh.\n`rmbc`                           Detect Windows-copies of files and move them to subdirectories.\n`scrapbook_overview`             Generate XHTML overview pages for directories with websites.\n`set_xdev_enabled`               Enable or disable ceratin X11 devices.\n`src_analyze`                    Generate very simple line number reports for source trees.\n`virshmigtui`                    Interactively migrate VMs between hosts.\n-------------------------------  ------------------------------------------------------------------\n\nBoxes\n=====\n\n## Synopsis\n\n\tboxes\n\n## Description\n\nASCII and Unicode art at its finest. This script displays boxes made of various\ncharacters. This may inspire the user to decide for/against using any of them\nin own shell scripts. The boxes are given in colorful sections, but the\nessence is as follows:\n\n~~~\n────────────── ┌────────────┐ ╔════════════╗ ■■■■■■■■■■■■■■ ██████████████\n│ TESTBOX 01 │ │ TESTBOX 02 │ ║ TESTBOX 03 ║ ■ TESTBOX 04 ■ █ TESTBOX 05 █\n────────────── └────────────┘ ╚════════════╝ ■■■■■■■■■■■■■■ ██████████████\n▀▀▀▀▀▀▀▀▀▀▀▀▀▀ ▄▄▄▄▄▄▄▄▄▄▄▄▄▄ ◘◘◘◘◘◘◘◘◘◘◘◘◘◘ ░░░░░░░░░░░░░░ ▒▒▒▒▒▒▒▒▒▒▒▒▒▒\n▌ TESTBOX 06 ▐ ▌ TESTBOX 07 ▐ ◘ TESTBOX 08 ◘ ░ TESTBOX 09 ░ ▒ TESTBOX 10 ▒\n▄▄▄▄▄▄▄▄▄▄▄▄▄▄ ▀▀▀▀▀▀▀▀▀▀▀▀▀▀ ◘◘◘◘◘◘◘◘◘◘◘◘◘◘ ░░░░░░░░░░░░░░ ▒▒▒▒▒▒▒▒▒▒▒▒▒▒\n▓▓▓▓▓▓▓▓▓▓▓▓▓▓\n▓ TESTBOX 11 ▓\n▓▓▓▓▓▓▓▓▓▓▓▓▓▓\n\n************** -------------- ############## ++++++++++++++ ==============\n* TESTBOX XX * | TESTBOX YY | # TESTBOX ZZ # + TESTBOX AA +   TESTBOX BB\n************** -------------- ############## ++++++++++++++ ==============\n°°°°°°°°°°°°°° ~~~~~~~~~~~~~~ \"\"\"\"\"\"\"\"\"\"\"\"\"\" ////////////// \\\\\\\\\\\\\\\\\\\\\\\\\\\\\n° TESTBOX CC °   TESTBOX YY     TESTBOX YY   / TESTBOX YY / \\ TESTBOX YY \\\n°°°°°°°°°°°°°° ~~~~~~~~~~~~~~ \"\"\"\"\"\"\"\"\"\"\"\"\"\" ////////////// \\\\\\\\\\\\\\\\\\\\\\\\\\\\\n\nxxxxxxxxxxxxxx XXXXXXXXXXXXXX mmmmmmmmmmmmmm iiiiiiiiiiiiii IIIIIIIIIIIIII\nx TESTBOX CC x X TESTBOX YY X   TESTBOX YY   i TESTBOX YY i I TESTBOX YY I\nxxxxxxxxxxxxxx XXXXXXXXXXXXXX mmmmmmmmmmmmmm iiiiiiiiiiiiii IIIIIIIIIIIIII\nwwwwwwwwwwwwww 11111111111111 llllllllllllll iiiiiiiiiiiiii IIIIIIIIIIIIII\nw TESTBOX CC w 1 TESTBOX YY 1 l TESTBOX YY l i TESTBOX YY i I TESTBOX YY I\nwwwwwwwwwwwwww 11111111111111 llllllllllllll iiiiiiiiiiiiii IIIIIIIIIIIIII\nWWWWWWWWWWWWWW MMMMMMMMMMMMMM uuuuuuuuuuuuuu UUUUUUUUUUUUUU oooooooooooooo\nW TESTBOX CC W M TESTBOX YY M u TESTBOX YY u U TESTBOX YY U o TESTBOX YY o\nWWWWWWWWWWWWWW MMMMMMMMMMMMMM uuuuuuuuuuuuuu UUUUUUUUUUUUUU oooooooooooooo\nOOOOOOOOOOOOOO 00000000000000 VVVVVVVVVVVVVV vvvvvvvvvvvvvv zzzzzzzzzzzzzz\nO TESTBOX CC O 0 TESTBOX YY 0 V TESTBOX YY V v TESTBOX YY v   TESTBOX YY  \nOOOOOOOOOOOOOO 00000000000000 VVVVVVVVVVVVVV vvvvvvvvvvvvvv zzzzzzzzzzzzzz\n~~~\n\n## See also\n\n * [dialog(1)](https://manpages.debian.org/buster/dialog/dialog.1.en.html)\n * [colortest-16b(1)](https://manpages.debian.org/buster/colortest/colortest-16b.1.en.html)\n\nDeltamount\n==========\n\n## Synopsis\n\n\tdeltamount src dest [delta]\n\n## Description\n\nThis script uses\n[aufs(5)](https://manpages.debian.org/buster/aufs-tools/aufs.5.en.html) from\npackage `aufs-tools` to create a writeable directoy which contains the files\nfrom `src`. Unlike a normal bind-mount, the changes made to the files in `dests`\nare not written back to `src` but instead to a third directory called `delta`.\n\nIf `delta` is not given, a temporary directory will automatically be created for\nit.\n\n## See also\n\n[aufs(5)](https://manpages.debian.org/buster/aufs-tools/aufs.5.en.html)\n\nFind Double Windows Filenames\n=============================\n\n## Synopsis\n\n\tfind_double_windows_file_names\n\n## Description\n\nThis script is an alias for the following pipeline:\n\n\t find . | tr A-Z a-z | sort | uniq -d\n\nIt checks if any file or directory names exist that would be considered “equal”\non platforms whose file systems do not act case-sensitive (like Windows).\n\n## Rationale\n\nThis script is most useful when merging multiple directories of the same folder\nstructure that originates from a Windows platform.\n\nA typical example is the installation of game mods for Windows games: They often\ncome in case-sensitive 7z-files and after extraction the files do not become\npart of the original game's file structure but rather add a new directory\nbesides the existing one that only differs in its writing (like. `DATA` vs.\n`Data` vs. `data` etc.).\n\nWhen running applications in Wine, they will only see one of the respective\ndirectories. Hence the need to avoid this situation.\n\n## See also\n\n`ma_rename_normalize` (documentation further below).\n\nGimp Convert to Indexed\n=======================\n\n## Synposis\n\n\tgimp_convert_to_indexed [INDICES]\n\n## Description\n\nProcesses all `.tga` files in the current directory and converts them to\nindexed PNG files. The default number of indices is 8 unless otherwise given\nas parameter.\n\n## Rationale\n\nThis script is useful to convert scanned images to indexed PNGs. Gimp has been\nfound to produce better output results than ImageMagick in this case.\n\n## See also\n\n[convert(1)](https://manpages.debian.org/buster/graphicsmagick-imagemagick-compat/convert.1.en.html)\n\nCryptvol\n========\n\n## Synopsis\n\n\tma_cryptvol\n\tma_cryptvol --init device\n\tma_cryptvol --mountcryptvol device mountpoint [delta] [submount] [devicename]\n\n## Description\n\nThis script is a wrapper around cryptsetup+LUKS to manage encrypted devices on\nLinux. It has three forms of invocation. By default, it attempts to mount the\ndevice specified in `~/.mdvl/cryptvol.conf` that needs to be prepared by the\nuser.\n\nAlternatively, the `--mountcyrptvol` option can be used to mount the device\ndirectly without preparing a configuration file. Finally, `--init` allows for\nexisting partitions to be formatted with encryption.\n\n## Options\n\n### `--init`\n\nInitializes a device node for use with cryptsetup+LUKS. This includes\ntemporarily mounting the formatted device and filling the whole file system\nwith random binary data (up to 4 TiB) by running [big4(32)](../32/big4.xhtml).\nThis process will interactively ask for the user's passphrase. Additionally,\ntwo directories `data` and `delta` will be created on the new encrypted\nfile system.\n\n### `--mountcryptvol`\n\nManually mounts an encrypted volume. By default, only a device file and\nmountpoint are needed. In case `deltamount` is to be instantiated for the\ntarget filesystem, parameters `delta`, `submount` and `devicename` can be\nused as follows:\n\n`delta`\n:   Boolean to enable deltamount capabilities.\n    Value 1 enables `deltamount`, value 0 bypasses ist.\n`submount`\n:   Directory to use for the actual (non-delta-mounted) file system.\n`devicename`\n:   Configures a name for the encrypted volume. Use a single file name\n    without any path parts (e.g.: `mydevicename` would be a valid name).\n\n## Files\n\nFile `~/.mdvl/cryptvol.conf` is sourced into `ma_cryptvol` and can contain the\nfollowing properties:\n\n`CRYPTVOL_UUID`\n:   UUID from `/dev/disk/by-uuid` to identify the encrypted volume with.\n`CRYPTVOL_MOUNTPOINT`\n:   Mountpoint to mount the encrypted volume to. If deltamount is enabled, this\n    directory's changes do not directly go to the `data` directory but are\n    stored in `delta`instread.\n`CRYPTVOL_DELTA`\n:   See `delta` above.\n`CRYPTVOL_SUBMOUNT`\n:   See `submount` above.\n`CRYPTVOL_DEVICE_NAME`\n:   See `devicename` above.\n\n## Environment Variables\n\n`MDVL_CRYPTVOL_CONF`\n:   When set, this file is used instead of `~/.mdvl/cryptvol.conf`.\n\n## See also\n\n * [cryptsetup(8)](https://manpages.debian.org/buster/cryptsetup-bin/cryptsetup.8.en.html)\n * `deltamount` (above)\n\nRename Normalize (DANGEROUS)\n============================\n\n## Synopsis\n\n\tma_rename_normalize [-l] [-a] [-x] [-s] [-c]\n\n## Description\n\nThis script _recursively_ (!) renames all files below the current working\ndirectory to conform to a certain naming style. Examples include: Changing file\nnames to lowercase or removing spaces.\n\nThis script is _dangerous_: Be sure not to invoke it on directory trees that\nare part of the operating system because most likely this will cause the OS\nto cease functioning! This script is mostly indented to rename files received\nfrom Windows hosts or other users that may contain characters which are\ndifficult to process in commandline environments.\n\nSpecial characters are replaced by `x`; spaces are replaced by `_`.\n\nWhenever files would be overwritten by the renaming, the user is interactively\nqueried for a choice to resolve the problem.\n\n## Options\n\n`-l`\n:   Convert all file names to lowercase.\n`-a`\n:   Remove german Umlaute (äöüÄÖÜß).\n`-x`\n:   Remove most symbol characters.\n`-s`\n:   Remove spaces (replace by `_`)\n`-c`\n:   Replace space|minus|space sequences by a single `_`.\n    This is useful when processing audio files which often use such naming.\n`-n`\n:   Print changes rather than applying them.\n    Unless you are experienced with using this script, you are higly recommeded\n    to _USE THIS OPTION_ before running without `-n`!\n\n## Rationale\n\nThis script can be used to resolve the conflicts detected by\n`find_double_windows_file_names`. For these usecases, it is recommended to only\nuse parameter `-l` (and `-n`).\n\nThis script is very talkative on the console output due to the high potential\nfor accidentially destroying something.\n\n## Bugs and Future Directions\n\nIt is currently not possible to filter out certain unicode abnominations\n(most notably: non-0x20 spaces and emojis) or filesnames which are not even\nunicode. This is due to the fact that a blacklist-style approach to filter out\ncertain characters and sequences is used. Such a feature may be added if found\nnecessary in the future.\n\n## See also\n\n * `find_double_windows_file_names` (above).\n\nScreen Mirroring\n================\n\n## Synopsis\n\n\tma_scrmir\n\n## Description\n\nThis script is intended to detect externally connected beamers/screens and\nswitch to _mirroring_ -- a mode that may be suitable for presentations and\nlive demonstrations of programs.\n\n## Bugs\n\nIt is expected that this automatism may fail in certain cases. Revert to using\n`xrandr` directly, then.\n\n## See also\n\n[xrandr(1)](https://manpages.debian.org/buster/x11-xserver-utils/xrandr.1.en.html)\n\nVNC Over SSH\n============\n\n## Synopsis\n\n\tma_vnc_over_ssh TARGET [SSHPARAMS [WM [REMOTE_DNR [LOCAL_DNR [DY [DX [VNCOPT]]]]]]]\n\n## Description\n\nThis script connects to a remote host over SSH, runs a VNC server and then\nconnects securely (i.e. over SSH) to the remotely started VNC server. Upon\nclosing the window, the remote VNC server will be stopped.\n\n## Options\n\nAll configuration needs to be passed by positional parameters. The script's code\nis such that it expects the parameters at fixed positions and hence, it is not\npossible to specify one of the “later” options while leaving out some of the\n“earilier” ones.\n\n`TARGET`\n:   SSH server (`user@hostname`) to connect to.\n`SSHPARAMS`\n:   Additional parameters to use for `ssh`. Can be used to specify a custom\n    identity file or different SSH server port etc.\n`WM`\n:   Window manager (e.g. `/usr/bin/icewm`) to invoke on the target machine.\n    If not specified, the server's default will be used.\n`REMOTE_DNR`\n:   X11 display number to use on the remote machine. Defaults to `41`\n    (`DISPLAY=:41`)\n`LOCAL_DNR`\n:   X11 display number to use on the local machine. Defaults to `2`\n    (`DISPLAY=:2`)\n`DY` and `DX`\n:   Number of pixels to subtract from screen size to calculate the VNC server's\n    screen dimension. It makes sense to set this to a value such that all window\n    decorations/panels etc. are subtracted. Defaults to DX=4, DY=40.\n`VNCOPT`\n:   Additional parameters to pass to `xtightvncviewer`.\n\n## Rationale\n\nSSH X-forwarding is much easier to use than VNC although the latter has some\ndistinctive advantages. On the downside, it does not encrypt securely by\ndefault and it is easy to accidentally hog resources by leaving remote VNC\nsessions open. To make VNC (almost) as easy to use as SSH X-forwarding, this\nscript was devised.\n\n## See also\n\n * [xtightvncviewer(1)](https://manpages.debian.org/buster/xtightvncviewer/xtightvncviewer.1.en.html)\n * University-specific version at \u003chttps://pastebin.com/J0J0qHjB\u003e\n\nRecursive Ma_Sys.ma Backup Copy (RMBC)\n======================================\n\n## Synopsis\n\n\trmbc\n\n## Description\n\nThis is a specialized script to process directories containing Windows-explorer\ncopies in format `Kopie (YYY) von ZZZ` where `YYY` is a number and `ZZZ` the\noriginal filename. The script identifies them and moves them to a directory\ncalled `backup_copies` and adds the number `YYY` to the highest number already\nin `backup_copies` to generate the name for new backup copies.\n\nBy default, `rmbc` works on the current working directory only unless configured\ndifferently by `rmbc_pre`\n\n## Rationale\n\nThis script was developed for working in a (German) Windows virtual machine with\na program that does not support _undo_ hence causing the need for frequent\nbackup copies to emulate such a behaviour.\n\n## Files\n\n`rmbc_pre`\n:   A hook file that is sourced before processing. It can set various\n    configuration values including the ability to enable recursive operation.\n`rmbc_post`\n:   A hook file that is sourced after processing all files.\n\n## Configuration values (default values)\n\n`BAK` (`.bak`)\n:   File extension to use for backup copies\n`DST` (`backup_copies`)\n:   Directory to move backup copies to\n`RECURSE` (`false`)\n:   Whether to act recursively or only on the present working directory.\n`POST` (`./rmbc_post`)\n:   Name of the hook to invoke after processing.\n`MV` (`mvdot`)\n:   Command to invoke for renaming files.\n    By default, it uses shell function `mvdot` (declared in `rmbc`) which will\n    print a `.` for each file moved.\n\nScrapBook Overview\n==================\n\n## Synopsis\n\n\tscrapbook_overview\n\n## Description\n\nThis script scans the current directory for HTML files stored in certain file\nstructures as produced by the old _ScrapBook_ Firefox Extension and later the\n_WebScrapBook_ extension. Additionally, it can be configured to process\nnon-ScrapBook entries (with limited capabilities), too.\n\nFrom all the files recognized, it compiles a single XHTML page that links to\nall the respective files. This can be used to generate _overview_ pages that\nmake finding the relevant pages easier.\n\n## Files\n\nFile `overview_conf.sh` is sourced and can configure the following variables\n(defaults listed in parentheses).\n\n`OUTPUT_FILE` (`overview.xhtml`)\n:   File name to write results to\n`APPEND_NON_SCRAPBOOK_ENTRIES` (`false`)\n:   Configure to append arbitrary files found in subdirectories.\n`SORT_AFTER_PREFIX` (`false`)\n:   Configure to add “sections” to the tabular output to distinguish different\n    directories.\n`WEBSCRAPBOOK` (`false`)\n:   Configure to extract titles from `index.html` files in subdirectories\n    (compatible with the _WebScrapBook_ Firefox extension's format).\n    Note that this cannot be combined with `APPEND_NON_SCRAPBOOK_ENTRIES`\n\n## Examples\n\nConsider the following file structure. All HTML files have been downloaded with\nextension _SavePageWE_. For the files in `subdir1`, the original file name\nwas retained; for `subdir2`, a file was renamed to `index.html` to emulate\nthe structure from _WebScrapBook_.\n\n\t./\n\t  |\n\t  +-- subdir1/\n\t  |    |\n\t  |    +-- 20201021181948zfsspeed.html\n\t  |    |\n\t  |    +-- 20201025144823neomutt.html\n\t  |    |\n\t  |    +-- 20201025145041mutt.html\n\t  |\n\t  +-- subdir2/\n\t  |    |\n\t  |    +-- index.html\n\t  |\n\t  +-- overview_conf.sh\n\n### Variant 1: Empty (or no) `overview_conf.sh`\n\nThis generates an empty `overveiw.xhtml` because none of the files in the\ndirectory structure originate from the original `ScrapBook` extension.\n\n### Variant 2: Set `WEBSCRAPBOOK=true`\n\n`overview_conf.sh` is as follows:\n\n\tWEBSCRAPBOOK=true\n\nOutput listing is as follows:\n\nDirectory  Title\n---------  --------------------------------------------------\nsubdir1     \nsubdir2    Big list of http static server one-liners - GitHub\n\nOne can see that it did not add any of the files from `subdir1` because there\nwas no `index.html`. For `subdir2`, however, the title was extracted properly\nand added to the overview table.\n\n### Variant 3: Set `APPEND_NON_SCRAPBOOK_ENTRIES=true`\n\n`overview_conf.sh` is as follows:\n\n\tAPPEND_NON_SCRAPBOOK_ENTRIES=true\n\nOutput listing is as follows:\n\nDirectory  Title\n---------  ---------------------------\nsubdir1    20201021181948zfsspeed.html\nsubdir1    20201025144823neomutt.html\nsubdir1    20201025145041mutt.html\nsubdir2    index.html\n\nOne can see that titles are not recognized, but all files are added to\n(and linked from) the overview.\n\n## Bugs\n\nThis shell script's coding style is awful!\n\n## See Also\n\n * [firefox_extension_modernization_issues(37)](../37/firefox_extension_modernization_issues.xhtml)\n * [WebScrapBook Firefox WebExtension](https://addons.mozilla.org/en-US/firefox/addon/webscrapbook/?utm_source=addons.mozilla.org\u0026utm_medium=referral\u0026utm_content=search)\n * [Save Page WE Firefox WebExtension](https://addons.mozilla.org/en-US/firefox/addon/save-page-we/)\n\nSet Xdev Enabled\n================\n\n## Synopsis\n\n\tset_xdev_enabled PATTERN \u003c0|1\u003e\n\n## Description\n\nEnabling and disabling X11 input devices can be a little tricky. This script\nprovides an interface that can accept IDs (`id=...` pattern) as well as _names_.\n\nUse `xinput list` to find out which inputs can be controlled this way.\n\n## Rationale\n\nNormally, it should not be necessary to enable/disable X11 devices. However,\nsome old Laptop's tracksticks malfunction and move the mouse pointer all the\ntime making mouse control impossible. It helps to disable their associated\ninput device and attach an external USB mouse.\n\n## See Also\n\n[xinput(1)](https://manpages.debian.org/buster/xinput/xinput.1.en.html)\n\nSrc Analyze\n===========\n\n## Synopsis\n\n\tsrc_analyze [PATTERN]\n\n## Description\n\nThis script is a more primitive version of the widely known `cloc` utility. It\nattempts to recursively count source code lines. Unlike `cloc`, however, it\nincludes counting empty lines and it does not automatically detect programming\nlanguage, but relies on a user-supplied pattern to search for files.\n\nThe report also reports each individual file size and is thus expected to help\nwith finding overly large source code files.\n\nBy default, it looks for `*.java`, i.e. scans for Java code.\n\n## Example\n\nHere is a sample output comparing `cloc` and `src_analyze` for the\n[big4(32)](../32/big4.xhtml)-Repository:\n\n~~~\n.../bo-big$ src_analyze\nSRC Analyze 1.0.4, Copyright (c) 2013, 2020 Ma_Sys.ma.\nFor further info send an e-mail to Ma_Sys.ma@web.de.\n\nListing ./latest\n\n322 ./latest/Big4.java\n\nListing ./legacy\n\n   23 ./legacy/Benchmark.java\n   85 ./legacy/Big.java\n  129 ./legacy/Big2.java\n  172 ./legacy/Big3.java\n  409 total\n\nSUM = 731 lines.\n\n.../bo-big$ cloc .\n       9 text files.\n       9 unique files.\n       2 files ignored.\n\ngithub.com/AlDanial/cloc v 1.81  T=0.04 s (217.6 files/s, 25488.3 lines/s)\n-------------------------------------------------------------------------------\nLanguage                     files          blank        comment           code\n-------------------------------------------------------------------------------\nJava                             5             74             16            641\nMarkdown                         1             31              0            131\nAnt                              1              7              3             32\nBourne Shell                     1              0              0              2\n-------------------------------------------------------------------------------\nSUM:                             8            112             19            806\n-------------------------------------------------------------------------------\n~~~\n\nNote that 641+16+74 = 731 i.e. while `cloc` reports lines by different types,\nit computes the same sum value if blanks and comments are included!\n\n## See also\n\n[cloc(1)](https://manpages.debian.org/buster/cloc/cloc.1.en.html)\n\nVirshMigTUI\n===========\n\n## Synopsis\n\n\tvishmigtui\n\n## Description\n\nThis script provides a terminal user interface (TUI) for migrating virtual\nmachines between different host systems using `virsh`. It has an interactive\ninterface realized by means of the `dialog` utility and scans a local\n`virt-manager.log` file for the different connection strings that may be used\nto connect to remote systems.\n\nUnlike the `virt-manager` GUI, it only allows doing _offline migrations_ i.e.\nrequires the VM to be shut down first. These can be performed quickly if both\nvirtual machine hosts are accessing the VMs in the same storage location and\non the same backend (e.g. NFS).\n\n## Rationale\n\nThis script was created to work around some issues with the live migration\nfeature and is expected to become obsolete once the live migration works\nproperly. If live migrations work for you, do not use it!\n\n## See also\n\n * [dialog(1)](https://manpages.debian.org/buster/dialog/dialog.1.en.html)\n * [virt-manager(1)](https://manpages.debian.org/buster/virt-manager/virt-manager.1.en.html)\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fm7a%2Flo-shellscripts","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fm7a%2Flo-shellscripts","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fm7a%2Flo-shellscripts/lists"}