Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > alt.comp.os.windows-10 > #179807
| From | Zaidy036 <Zaidy036@air.isp.spam> |
|---|---|
| Newsgroups | alt.comp.os.windows-10, alt.comp.os.windows-11 |
| Subject | Re: {rightclick} New | Text Document |
| Date | 2024-11-09 10:20 -0500 |
| Organization | A noiseless patient Spider |
| Message-ID | <vgnujl$3p1tp$1@dont-email.me> (permalink) |
| References | (1 earlier) <vgk1be$cmdj$1@news.samoylyk.net> <vgkgt0$34b07$1@dont-email.me> <vgl6cs$1kf7$1@news.samoylyk.net> <vgltr1$3brmr$1@dont-email.me> <vgmnip$5uia$1@news.samoylyk.net> |
Cross-posted to 2 groups.
On 11/8/2024 11:14 PM, Wolf Greenblatt wrote: > On Fri, 8 Nov 2024 21:53:12 +0100, Herbert Kleebauer wrote: > >>> How the App Paths Registry Key Makes Windows Both Faster and Safer >>> https://helgeklein.com/blog/how-the-app-paths-registry-key-makes-windows-both-faster-and-safer/ >> >> I don't see why it will make Windows "Faster and Safer". > > I don't either. All I know is when Microsoft gave us the System Registry, I > studied how it works & one of the neat things I found was 'App Paths'. > https://docs.revenera.com/installshield22helplib/helplibrary/IHelpAddAppPathsToComponent.htm > > I latched on to the convenience of the App Paths subkey & its portability. > https://learn.microsoft.com/en-us/windows/win32/shell/app-registration > > This was so long ago that I don't remember if it was Windows XP or 95 or > what, but I made scores of commands those days I'm still using today. > > HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\App Paths > Used to register an application for a single user > > HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\App Paths > Used to register an application for all users of the computer > > I simply export the App Paths key from one machine & load it into another. > It just works. And I've been using literally that same key for decades. > https://superuser.com/questions/1642149/what-does-hklm-software-microsoft-windows-currentversion-app-paths-actually-do > > You export from one machine. You import into the new machine. > And all your commands work the same on both machines. > > Of course I also bring over my batch & link directories (which contain > almost every script ever proposed on the Windows newsgroups, by the way). > > And, of course, you can screw with the PATH and they'd likely still work. > But I have never touched the PATH on Windows in decades as I don't need to. > >>>> Create a folder and add it to the PATH environment variable* (which is >>>> something you only need to do once). After that you can just drop any >>>> program or batch file into it and start it using the "run" dialog (or from a >>>> command console) - no "app path" fumbling needed anymore. >>> >>> The article cited explains why it's sophomoric to modify the PATH variable. >> >> There is nothing explained. > > Agree with you. > > You're different than that other guy who was just complaining so I didn't > take him seriously. I take you seriously as you're not just complaining. > > You're trying to be critically constructive. And that's good. So am I. > > Many of my programs are those you wrote that I found on the archives for > this newsgroup whenever I search for things - like your spelling program. > > I love that it gives me three chances to spell a word and if I get it > right, then it removes the word from my misspelled word list. > > It's great! I think you wrote half the batch scripts that I've used, > although others wrote them too (like Zaidy036) as I copy them verbatim and > then when they work for me verbatim, I then modify them as needed. > > I think you wrote my sort program, for example, that sorts by microsecond. > And I think you wrote the program I use that gets rid of the command > console when I run commands which leave an unnecessary console in place. > > I never understood that (as it makes use of certificates) - but it works! > showwin.exe 5 > del showwin.exe > goto :eof > > -----BEGIN CERTIFICATE----- > TVpgAQEAAAAEAAAA//8AAGABAAAAAAAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA > AAAAAAAAAAAAAAAAoAAAAA4fug4AtAnNIbgBTM0hTmljZSB0byBtZWV0IHNvbWVi > b2R5IHdobyBpcyBzdGlsbCB1c2luZyBET1MsDQpidXQgdGhpcyBwcm9ncmFtIHJl > cXVpcmVzIFdpbjMyLg0KJFBFAABMAQEAUHmlNgAAAAAAAAAA4AAPAQsBBQwAAgAA > AAAAAAAAAADIEAAAABAAAAAgAAAAAEAAABAAAAACAAAFAAAAAAAAAAQAAAAAAAAA > ACAAAAACAAAAAAAAAwAAAAAAEAAAEAAAAAAQAAAQAAAAAAAAEAAAAAAAAAAAAAAA > GBAAADwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA > AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAQAAAYAAAA > AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAALnRleHQAAAAmAQAAABAAAAACAAAAAgAA > AAAAAAAAAAAAAAAAIAAA4AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA > AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABoEAAAAAAAAJQQAACmEAAA > uhAAAAAAAABgEAAAAAAAAAAAAABUEAAAABAAAIQQAAAAAAAAAAAAAHYQAAAIEAAA > AAAAAAAAAAAAAAAAAAAAAAAAAABVU0VSMzIuZGxsAABoEAAAAAAAAAAAU2hvd1dp > bmRvdwAAS0VSTkVMMzIuZGxsAACUEAAAphAAALoQAAAAAAAAAABHZXRDb21tYW5k > TGluZUEAAABHZXRDb25zb2xlV2luZG93AAAAAEV4aXRQcm9jZXNzAP8VCBBAADHS > SECAOAB0EYA4InUC99IJ0nXvgDggdepAMfa9BQAAAA+2EEAI0nQTgOowcvOA+gl3 > 7mv2CgHWMe3r5QntdAKJ7v8VDBBAAFZQ/xUAEEAAagD/FRAQQAAAAAAAAAAAAAAA > AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA > AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA > AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA > AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA > AAAAAAAAAAAAAAAAAAAAAA== > -----END CERTIFICATE----- > > Some day I'll actually understand what you did in the above that works. > > But for now, I just type "x" in my Runbox to open the directory and then I > type the batch file that you wrote that runs what I need w/o the console! > > (I never put the two together so that the Runbox command would do both > tasks of going to the directory and running the command - because it's NOT > in the PATH since I never mess with the path - which takes us full circle.) > >>> The App Paths key provides a per-process PATH configuration which increases >>> security by eliminating the need to touch the global system PATH variable. >> >> Why does this increase security? > > I don't know. I was just trying to get rid of the guy who was complaining > about how Microsoft does the PATH. I told him to complain to Bill Gates. > > I'm just using a feature of the PATH that I've been using for decades. > It's why I never have to modify the PATH. > >> A Windows App normally isn't just a single exe file but comes with a lot >> of additional files, so it needs its own program directory. If you have >> a lot of such Apps installed it would be indeed a stupid idea to add all >> these program directories to the PATH variable. On the other side, if >> you have dozens of single file utilities or batch files, then it would >> be stupid, to spread them all over the disk and use a Registry entry >> for each of them. Just put them all in a single command directory and >> add it to the PATH variable. > > That works too. But not every command is a batch file. Some are links. > Links do things easily that batch files don't do as easily, although both > can be made to do everything I'm sure. > > Where I use links is when I have to bring up the Windows task scheduler. > > Usually I do that only to run commands which need admin privileges. > Or when I want to pin something to the taskbar that won't pin otherwise. > > I'm not using the App Paths for any other reason than convenience. > And portability. > > Because the Windows App Paths key does more than just run batch files. > >> When setting up a new PC, the first thing I do, is to copy this command >> directory to the new PC and modify the PATH variable. Then my collection >> of helper utilities is immediately available. > > Yup. I do something similar in that I set up all my concurrent machines and > the new machine the same as I set it up on Windows XP and moved forward. > > Over time, of course, there are tweaks (for example, the executable for > %Windir%\System32\curl.exe ifconfig.me didn't exist in early Windows 10), > but essentially the App Paths key contains everything I run every day. > > We both accomplish that portability in a very consistent way. > Only different. > > I never mess with the PATH. You do. > You never mess with the App Paths subkey. I do. > > The end result is similar and only slightly different from your approach. > Your approach is typical. Mine is perhaps not as typical. Both work. > > There are other methods also to find any given command on Windows. > https://learn.microsoft.com/en-us/windows/win32/shell/app-registration > >>> When I want template #1 for example, I type "1" in the Runbox. >>> When I want template #2, I type "2"; "3" for template #3, etc. >> >> Instead of typing <WIN>-R I prefer to have a CMD window open all >> the time. > > Rest assured I *never* type "Win+R". I just type that because most people > don't know anything about the runbox so it makes it clear for *them*. > > I keep a runbox shortcut pinned to teh taskbar in a prominent spot. > > (I just added "prominent" to my spelling list you created, as I had spelled > it "prominant" by mistake and it got squiggled so I added it to your list.) > >> I simple click into the task bar brings it to foreground >> so you can enter the commands. But when using the AppPath method >> to register 1.exe, 2.exe and 3.exe you have to type "start 1", >> "start 2" or "start 3", 1, 2 or 3 works only with the PATH method. > > Each method works. Neither is "abuse" of the mechanism Microsoft provided. > > As the other guy already said, the best way to do this (using either > method) is to write a script that has as input which template you want. > command template1 > command template2 > command template3 > > What would be a neat trick, although I don't need it, is to populate the > clipboard not with a "type file.txt | clip" but with a word document or an > excel spreadsheet (where "type" won't likely work for those templates). > > I don't have that script but if someone posts it, I'll use it. > Most of my stuff is written by you & others like Zaidy03 <Eric@Bloch.com>. Thanks for the mention. If I was doing something similar I would use one batch and its first step would be to ask how many (0-9) , kill batch if 0 otherwise use the number to do what I want. Why have multiple batches when one will work and take less file space? The make a shortcut to start the batch and perhaps also a "Shortcut Key" which would give efficient activation.+
Back to alt.comp.os.windows-10 | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
{rightclick} New | Text Document Wolf Greenblatt <wolf@greenblatt.net> - 2024-10-15 08:47 -0400
Re: {rightclick} New | Text Document Big Al <alan@invalid.com> - 2024-10-15 09:53 -0400
Re: {rightclick} New | Text Document Herbert Kleebauer <klee@unibwm.de> - 2024-10-15 16:43 +0200
Re: {rightclick} New | Text Document Wolf Greenblatt <wolf@greenblatt.net> - 2024-10-15 13:04 -0400
Re: {rightclick} New | Text Document Herbert Kleebauer <klee@unibwm.de> - 2024-10-16 00:44 +0200
Re: {rightclick} New | Text Document Herbert Kleebauer <klee@unibwm.de> - 2024-10-16 01:49 +0200
Re: {rightclick} New | Text Document Wolf Greenblatt <wolf@greenblatt.net> - 2024-10-15 23:12 -0400
Re: {rightclick} New | Text Document Herbert Kleebauer <klee@unibwm.de> - 2024-10-16 09:44 +0200
Re: {rightclick} New | Text Document Wolf Greenblatt <wolf@greenblatt.net> - 2024-10-16 16:31 -0400
Re: {rightclick} New | Text Document Newyana2 <newyana@invalid.nospam> - 2024-10-16 08:52 -0400
Re: {rightclick} New | Text Document Newyana2 <newyana@invalid.nospam> - 2024-10-15 11:26 -0400
Re: {rightclick} New | Text Document Paul <nospam@needed.invalid> - 2024-10-15 13:38 -0400
Re: {rightclick} New | Text Document Wolf Greenblatt <wolf@greenblatt.net> - 2024-11-07 22:42 -0500
Re: {rightclick} New | Text Document "R.Wieser" <address@is.invalid> - 2024-11-08 09:07 +0100
Re: {rightclick} New | Text Document Wolf Greenblatt <wolf@greenblatt.net> - 2024-11-08 09:14 -0500
Re: {rightclick} New | Text Document "R.Wieser" <address@is.invalid> - 2024-11-08 17:18 +0100
Re: {rightclick} New | Text Document Wolf Greenblatt <wolf@greenblatt.net> - 2024-11-08 13:58 -0500
Re: {rightclick} New | Text Document "R.Wieser" <address@is.invalid> - 2024-11-08 22:18 +0100
Re: {rightclick} New | Text Document Wolf Greenblatt <wolf@greenblatt.net> - 2024-11-08 20:24 -0500
Re: {rightclick} New | Text Document "R.Wieser" <address@is.invalid> - 2024-11-09 10:22 +0100
Re: {rightclick} New | Text Document "R.Wieser" <address@is.invalid> - 2024-11-08 17:30 +0100
Re: {rightclick} New | Text Document Herbert Kleebauer <klee@unibwm.de> - 2024-11-08 21:53 +0100
Re: {rightclick} New | Text Document Wolf Greenblatt <wolf@greenblatt.net> - 2024-11-08 23:14 -0500
Re: {rightclick} New | Text Document Zaidy036 <Zaidy036@air.isp.spam> - 2024-11-09 10:20 -0500
Re: {rightclick} New | Text Document Wolf Greenblatt <wolf@greenblatt.net> - 2024-11-25 17:50 -0500
Re: {rightclick} New | Text Document Herbert Kleebauer <klee@unibwm.de> - 2024-11-09 16:35 +0100
Re: {rightclick} New | Text Document Herbert Kleebauer <klee@unibwm.de> - 2024-11-09 16:36 +0100
Re: {rightclick} New | Text Document Herbert Kleebauer <klee@unibwm.de> - 2024-11-09 16:37 +0100
Re: {rightclick} New | Text Document Herbert Kleebauer <klee@unibwm.de> - 2024-11-09 16:38 +0100
Re: {rightclick} New | Text Document Wolf Greenblatt <wolf@greenblatt.net> - 2024-11-25 18:04 -0500
csiph-web