Programatically change the programs associated with a file extension in Windows

https://ss64.com/nt/ftype.html https://ss64.com/nt/assoc.html https://www.emacswiki.org/emacs/WThirtyTwoFileAssociations To use the emacs client as the editor associated with certain file extension, use the ftype and assoc commands. Run the followin as admin: ftype Emacs.org=<emacs-path>\emacsclientw -na runemacs "%1" ftype Emacs.el=<emacs-path>\emacsclientw -na runemacs "%1" rem ftype txtfile=<emacs-path>\emacsclientw -na runemacs "%1" assoc .txt=txtfile assoc .org=Emacs.org assoc .el=Emacs.el To add the option to open a file with emacs, edit the following registry file, substituting the .el extension with one you want to open with Emacs, and import in regedit:...

Fernando Costa Bertoldi

Run commands on startup on Windows

To run a command for all users on startup, add a shortcut to the shell:common startup folder C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Startup To run for your specific user on startup, add it to the shell:startup folder F:\Users\<user>\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\Startup To open one the above folders, type the shell command (either shell:startup or shell:common startup) in the Run prompt (Win+R) or in the Windows Explorer address bar (Win+E) SysInternals’ Autoruns lists all auto-starting programs

Fernando Costa Bertoldi

Run emacs server in Windows

We can also run the emacs server as a daemon on user init in Windows. We take advantage of the user startup folder, where you can put a batch script or shortcut which will be executed on user login. Go to the Roaming startup folder by either opening Run Command (Win+R) and typing shell:startup, or opening the Windows Explorer (Win+E) and typing shell:startup in the address bar Create a shortcup by right-clicking, new->shortcut....

Fernando Costa Bertoldi

Turn off annoying alarm sounds on Windows

https://www.digitalcitizen.life/when-each-sound-windows-sound-scheme-played/ Actual path in the above article is wrong, see where to go below. Windows by default plays annoying sounds when something fails in a program, e.g. when the search in Firefox or other programs finds zero occurrences, or in any editor, just trying to move the cursor past the end of the file. To turn off these sounds: go to Control Panel->Hardware and Sounds->Alter System Sounds change the sound file to (None) for the following events: Windows/Asterisk Windows/Default Beep Windows/Exclamation...

Fernando Costa Bertoldi