• Creating new files of indeterminate sort?

    From J. P. Gilliver@21:1/5 to All on Mon Jul 28 12:39:34 2025
    Is there any way to add something of the sort to the "New ..." menu in
    File Manager?

    I recently wanted to create a .css file, for example. The only way I
    know is to create a new text file (that's the only option that makes a
    file of zero size), then rename it, accepting the warning about changing
    the extension. (Or create and edit it as a text file, then have to
    fiddle with the name in the save function in Notepad or whatever editor.)
    --
    J. P. Gilliver. UMRA: 1960/<1985 MB++G()AL-IS-Ch++(p)Ar@T+H+Sh0!:`)DNAf

    "Everyone is entitled to an *informed* opinion." - Harlan Ellison

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Paul@21:1/5 to J. P. Gilliver on Mon Jul 28 08:18:40 2025
    On Mon, 7/28/2025 7:39 AM, J. P. Gilliver wrote:
    Is there any way to add something of the sort to the "New ..." menu in
    File Manager?

    I recently wanted to create a .css file, for example. The only way I
    know is to create a new text file (that's the only option that makes a
    file of zero size), then rename it, accepting the warning about changing
    the extension. (Or create and edit it as a text file, then have to
    fiddle with the name in the save function in Notepad or whatever editor.)


    There probably is a way to make a .css file from a menu.

    In Notepad, setting the filetype to "All Files" and saving as "some.css"
    seems to give a CSS file without a .txt glued to the end. It does not
    look like the operation is that much of a trauma, to be done manually :-)

    On the Macintosh, there was a utility called "FileTyper" which everyone
    used, and that is the rough equivalent of changing the extension from
    .txt to .css . It's a popular topic, this object oriented override wish
    we have. On their utility, it still takes typing, to make the change.
    Just in case you were thinking the utility was a mind reader and did
    the right thing without asking.

    But making a menu with the creation capability for 200 item types,
    does that make sense ? That's what we have to ask. On Linux, there
    is one wildcard file type and it is a "New.txt" kind of thing (users
    edit the details), there is a folder creation item and so on. They
    don't have 200 file types in their menu, and they also don't even
    rely on the extension for identifying files. A CSS would be detected
    by having "CSS constructs" or a "CSS magic number" near the top of the file.

    On Linux, there are at least 100 different text file types which the
    "file" utility recognizes. Including text file types I would claim
    to you are "damaged goods", Linux identifies them as if they
    exist intentionally. Like a text file, where the line termination
    style changes... half way through the document. Linux has a detection
    for that.

    Summary: There will always be a need for the user to do some things manually.
    A utility for such a purpose, would still need a gigantic menu,
    or a hole to type the identifier of the file type, so it's pretty
    hard to avoid the manual labour. Even if an AI was involved, you
    would still have to say "make this a CSS for me", so there is still
    a selection step. If you didn't tell the AI exactly what to do, it
    would be just as likely to "find and delete your database for you" :-)
    AI have that special something, called "a lack of common sense".
    They're the helper, that always spills your drink, before getting
    to the table.

    Paul

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Philip Herlihy@21:1/5 to All on Mon Jul 28 13:40:22 2025
    In article <1067nhn$21tqk$[email protected]>, [email protected] says...

    Is there any way to add something of the sort to the "New ..." menu in
    File Manager?

    I recently wanted to create a .css file, for example. The only way I
    know is to create a new text file (that's the only option that makes a
    file of zero size), then rename it, accepting the warning about changing
    the extension. (Or create and edit it as a text file, then have to
    fiddle with the name in the save function in Notepad or whatever editor.)


    I asked Perplexity.ai: "In Windows, when you right click within a
    folder or on the desktop, the context menu offers options to create New
    files of various types. How can I add to that list, so that I could
    create, for example, a new file of type .css?"

    Here's what it came back with:

    To add a file type like .css to the Windows context menu's "New" submenu
    (shown when you right click in a folder or on the desktop), you need to
    edit the Windows Registry. Here?s a step-by-step guide for adding a new
    .css file option:

    Steps to Add a .css File Option
    Open the Registry Editor

    Press Windows + R, type regedit, and hit Enter.

    Navigate to the Right Location

    Go to: HKEY_CLASSES_ROOT

    Scroll down to find the extension you want. If .css is not present,
    create it:

    Right-click on HKEY_CLASSES_ROOT

    Select New > Key

    Name the key: .css

    Create the ShellNew Key

    Right-click on the .css key you just created

    Select New > Key

    Name this new key: ShellNew

    Add the NullFile Value (for a blank .css file)

    With ShellNew selected, right-click in the right pane

    Select New > String Value

    Name it: NullFile

    Leave its value empty

    This will create a new blank .css file when you choose "New > Cascading
    Style Sheet Document" from the context menu.

    Optional step: If you want new .css files to contain template content,
    instead of NullFile, use a string value named FileName and set it to
    point to a template file (such as css.css in C:\Windows\ShellNew\):

    text
    "FileName"="css.css"
    Applying Changes
    Restart File Explorer (or reboot) for the new menu item to appear.

    Sample Registry Entry
    If you prefer, you can create a .reg file with the following contents,
    then run it:


    Windows Registry Editor Version 5.00

    [HKEY_CLASSES_ROOT\.css]
    @="cssfile"

    [HKEY_CLASSES_ROOT\.css\ShellNew]
    "NullFile"=""
    Save this into a file like add-css-to-context-menu.reg and double-click
    it to add the entry.

    After completing these steps, you will see "Cascading Style Sheet
    Document" (.css) as an option in your right-click "New" menu, letting
    you quickly create new .css files wherever you need them.

    --

    Phil, London

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From R.Wieser@21:1/5 to All on Mon Jul 28 14:49:38 2025
    J.P. ,

    Is there any way to add something of the sort to the "New ..." menu in
    File Manager?

    If you have no problem with manually editing the registry, there sure is in
    my ancient OS (XPsp3) - meaning I'm not at all sure if it still works/works
    the same under W10, but give it a go.

    Personally I've added an entry for a new .HTM file, and I expect it to work
    the same for any other filetype. Its done like this :

    Open the registry and add the following :
    - - - - - - - - - - -
    [HKEY_CLASSES_ROOT\.css\ShellNew]
    "FileName"="Template.css"
    - - - - - - - - - - -
    (the "HKEY_CLASSES_ROOT\.css" folder should already exist.)

    After that navigate to the "%USERPROFILE%\Templates" folder, and create a
    new "Template.css" file. Put whatever you want as the default in it (like "<style>" at the top, some blank lines and "</style>" at the bottom).

    Thats all it should need. Hope it helps.

    Regards,
    Rudy Wieser

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Alan K.@21:1/5 to J. P. Gilliver on Mon Jul 28 08:53:07 2025
    On 7/28/25 7:39 AM, J. P. Gilliver wrote:
    Is there any way to add something of the sort to the "New ..." menu in
    File Manager?

    I recently wanted to create a .css file, for example. The only way I
    know is to create a new text file (that's the only option that makes a
    file of zero size), then rename it, accepting the warning about changing
    the extension. (Or create and edit it as a text file, then have to
    fiddle with the name in the save function in Notepad or whatever editor.)
    There seems to be. I'm not able to get to my Windows machine to verify this but I've
    added one or two to my system. Also removed a few.

    https://www.nirsoft.net/utils/shell_menu_new.html
    This is a nice utility to edit/remove items from the right click 'new' menu. Not sure it allows adding though.

    Copilot seems to think this is a valid way to manually add an item. ---------------
    🛠️ Steps to Add a New File Type to 'New' Menu:

    Open Registry Editor:
    Press Win + R, type regedit, and hit Enter.

    Navigate to File Extension Key:
    Go to HKEY_CLASSES_ROOT\.sh (for Bash scripts, for example).

    If the key doesn’t exist, create it.

    Create or Open the ShellNew Key:

    Right-click on .sh, choose New > Key, name it ShellNew.

    Add a String or DWORD Value: You have options here:

    Add a NullFile entry (no value): creates a blank file when used.

    Or add a FileName string value pointing to a template (e.g., "FileName"="template.sh").
    Place the template in C:\Windows\ShellNew\.

    Confirm It Works:

    Right-click on the desktop or in a folder, open the “New” submenu, and your new file type
    should appear.
    ----------------------------------------------

    Also it gives this registry key and says the key governs file type handlers. HKEY_CLASSES_ROOT\.extension\ShellNew

    Maybe this gets you started. Bottom line is, yes, it can be done.

    --
    Linux Mint 22.1, Thunderbird 128.13.0esr, Mozilla Firefox 141.0
    Alan K.

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Herbert Kleebauer@21:1/5 to J. P. Gilliver on Mon Jul 28 17:01:55 2025
    On 7/28/2025 1:39 PM, J. P. Gilliver wrote:

    Is there any way to add something of the sort to the "New ..." menu in
    File Manager?

    I recently wanted to create a .css file, for example.

    And there maybe are other like .doc .bat .cmd .log .exe and so on.
    If you create an entry in the right-click menu for any of this
    file types, it becomes very confusing.

    The only way I
    know is to create a new text file (that's the only option that makes a
    file of zero size), then rename it,

    Whats wrong with just one entry for the most used type .txt? If
    you create it, the default file name is already highlighted so
    all you have to is to press <CTRL>-A and the new name including
    the .css. That are just 5 keystrokes more (<CTRL>-A .css) than
    you would have to enter for a separate entry for .css .

    accepting the warning about changing the extension.

    You are right, that requires an extra <RETURN>, so in total it
    makes 6 additional keystrokes, but as a reward you get a clean
    right-click menu.

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From R.Wieser@21:1/5 to All on Mon Jul 28 17:21:12 2025
    Herbert,

    You are right, that requires an extra <RETURN>, so in total it
    makes 6 additional keystrokes, but as a reward you get a clean
    right-click menu.

    My right-click menu is quote clean, as all it contains a "new" submenu
    (holding all the choices).

    Also, creating a new document using the right-click -> "new" menu allows you
    to load a template (a file containing the basic setup for the extension).

    iow, even for a .css file it saves you quite a bit more than 6 keystrokes.
    And quite a bit more for a basic .htm file.

    Regards,
    Rudy Wieser

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From J. P. Gilliver@21:1/5 to Paul on Mon Jul 28 16:46:19 2025
    On 2025/7/28 13:18:40, Paul wrote:
    On Mon, 7/28/2025 7:39 AM, J. P. Gilliver wrote:
    Is there any way to add something of the sort to the "New ..." menu in
    File Manager?

    I recently wanted to create a .css file, for example. The only way I
    know is to create a new text file (that's the only option that makes a
    file of zero size), then rename it, accepting the warning about changing
    the extension. (Or create and edit it as a text file, then have to
    fiddle with the name in the save function in Notepad or whatever editor.)


    There probably is a way to make a .css file from a menu.

    Thanks, and to Philip, R., and Alan who told me how to add a new
    filetypw by editing the registry.

    I was just wondering, if there's any way to add - say - "new file", that
    would let you specify any (or no!) extension when you typed in the name.

    Thinking about it, that wouldn't save you _that_ much time, as you'd
    still have to select which editor when you wanted to actually put
    something _in_ it after creating it. (Though I have vague memory of some
    way to specify an editor to be used for any [all] "unknown" types.)>
    In Notepad, setting the filetype to "All Files" and saving as "some.css" seems to give a CSS file without a .txt glued to the end. It does not
    look like the operation is that much of a trauma, to be done manually :-)

    No, putting the filename "in quotes" is the way to override the default extension in Notepad (and, I'm pretty sure, assorted other things too).

    []

    But making a menu with the creation capability for 200 item types,
    does that make sense ? That's what we have to ask. On Linux, there

    That, indeed, is why I was after a generic.

    []

    --
    J. P. Gilliver. UMRA: 1960/<1985 MB++G()AL-IS-Ch++(p)Ar@T+H+Sh0!:`)DNAf

    At the age of 7, Julia Elizabeth Wells could sing notes only dogs could
    hear.

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From knuttle@21:1/5 to Philip Herlihy on Mon Jul 28 12:43:05 2025
    On 07/28/2025 8:40 AM, Philip Herlihy wrote:
    In article <1067nhn$21tqk$[email protected]>, [email protected] says...

    Is there any way to add something of the sort to the "New ..." menu in
    File Manager?

    I recently wanted to create a .css file, for example. The only way I
    know is to create a new text file (that's the only option that makes a
    file of zero size), then rename it, accepting the warning about changing
    the extension. (Or create and edit it as a text file, then have to
    fiddle with the name in the save function in Notepad or whatever editor.)


    I asked Perplexity.ai: "In Windows, when you right click within a
    folder or on the desktop, the context menu offers options to create New
    files of various types. How can I add to that list, so that I could
    create, for example, a new file of type .css?"

    Here's what it came back with:

    To add a file type like .css to the Windows context menu's "New" submenu (shown when you right click in a folder or on the desktop), you need to
    edit the Windows Registry. Here?s a step-by-step guide for adding a new
    .css file option:

    Steps to Add a .css File Option
    Open the Registry Editor

    Press Windows + R, type regedit, and hit Enter.

    Navigate to the Right Location

    Go to: HKEY_CLASSES_ROOT

    Scroll down to find the extension you want. If .css is not present,
    create it:

    Right-click on HKEY_CLASSES_ROOT

    Select New > Key

    Name the key: .css

    Create the ShellNew Key

    Right-click on the .css key you just created

    Select New > Key

    Name this new key: ShellNew

    Add the NullFile Value (for a blank .css file)

    With ShellNew selected, right-click in the right pane

    Select New > String Value

    Name it: NullFile

    Leave its value empty

    This will create a new blank .css file when you choose "New > Cascading
    Style Sheet Document" from the context menu.

    Optional step: If you want new .css files to contain template content, instead of NullFile, use a string value named FileName and set it to
    point to a template file (such as css.css in C:\Windows\ShellNew\):

    text
    "FileName"="css.css"
    Applying Changes
    Restart File Explorer (or reboot) for the new menu item to appear.

    Sample Registry Entry
    If you prefer, you can create a .reg file with the following contents,
    then run it:


    Windows Registry Editor Version 5.00

    [HKEY_CLASSES_ROOT\.css]
    @="cssfile"

    [HKEY_CLASSES_ROOT\.css\ShellNew]
    "NullFile"=""
    Save this into a file like add-css-to-context-menu.reg and double-click
    it to add the entry.

    After completing these steps, you will see "Cascading Style Sheet
    Document" (.css) as an option in your right-click "New" menu, letting
    you quickly create new .css files wherever you need them.

    It is easier to open the Notepad form the Start, type the instruction
    you what in the new CSS file, and save with as "YOURFILENAME.css" in the appropriate directory.

    I do it all of the time writing BAT files. I open the Notepad and write
    the instruction I want. Leaving Notepad open, I save the BAT file in
    the directory where it is to be used. If it does not work I go back to Notepad, make the correction and save the correction to revise my BAT file.

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From R.Wieser@21:1/5 to All on Mon Jul 28 18:51:39 2025
    J.P. ,

    I was just wondering, if there's any way to add - say - "new file", that would let you specify any (or no!) extension when you typed in the name.

    On my machine that is what happens by default : if you forget the extension none is used. When you use an extension than that one is used. In both
    cases you get a warning though

    Thinking about it, that wouldn't save you _that_ much time, as you'd
    still have to select which editor when you wanted to actually put
    something _in_ it after creating it. (Though I have vague memory of
    some way to specify an editor to be used for any [all] "unknown" types.)

    You can give the .css entry in the registry some stuff to mimic the .txt
    entry. That way all you would need to do is to double-click the .css file
    to have it open in the standard text editor.

    I my (XPsp3) case thats :
    - - - - - - - - - - - - - -
    HKEY_CLASSES_ROOT\.css\PersistentHandler @={eec97550-47a9-11cf-b952-00aa0051fe20}
    - - - - - - - - - - - - - -

    if you want to be able to select your own editor to open it with it goes
    like this
    - - - - - - - - - - - - - -
    HKEY_CLASSES_ROOT\.css\Shell\Open\Command
    @="C:\WINDOWS\system32\write.exe" "%1"
    - - - - - - - - - - - - - -

    Hope that helps.

    Regards,
    Rudy Wieser

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From J. P. Gilliver@21:1/5 to J. P. Gilliver on Mon Jul 28 19:10:45 2025
    XPost: comp.internet.services.video.youtube

    On 2025/7/28 18:18:55, J. P. Gilliver wrote:
    (This reply is by email)

    Sorry, Thunderbird decided the email failed, so sent it to a newsgroup -
    but I think wrong one. (Without asking me, I think.)>
    On 2025/7/28 17:51:39, R.Wieser wrote:
    J.P. ,

    I was just wondering, if there's any way to add - say - "new file", that >>> would let you specify any (or no!) extension when you typed in the name.

    On my machine that is what happens by default : if you forget the extension >> none is used. When you use an extension than that one is used. In both
    cases you get a warning though

    I think we're talking about different things. I'm talking about right-clicking in a folder (in File Explorer), and selecting New: that
    offers Folder, Shortcut, and (in my case) ten filetypes, from Windows
    Batch File to Text Document. You can't "forget" the extension - when you select one of the options, it preloads the extension (e. g. if you
    select Text Document, it creates "New Text Document.txt", with the part before the dot highlighted for you to tye-replace. (IIRR, on 7 and
    earlier it created "Untitled.txt", again with the first part highlighted.)

    []

    You can give the .css entry in the registry some stuff to mimic the .txt

    []

    I wasn't trying to add a _specific_ new type (such as .css); I was
    wondering if there was any way to add a _generic_ "new file" to the list
    (of things it can create).

    --
    J. P. Gilliver

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From R.Wieser@21:1/5 to All on Mon Jul 28 22:18:49 2025
    XPost: comp.internet.services.video.youtube

    J. P. ,

    On my machine that is what happens by default : if you forget the
    extension none is used. When you use an extension than that one
    is used. In both cases you get a warning though

    I think we're talking about different things. I'm talking about
    right-clicking in a folder (in File Explorer), and selecting New:

    Don't worry, we are talking about the same thing.

    You can't "forget" the extension - when you
    select one of the options, it preloads the extension (e. g. if you
    select Text Document, it creates "New Text Document.txt", with
    the part before the dot highlighted for you to tye-replace.

    Well, that is different from what happens on my XP machine - there the whole name (including the extension) is hi-lited. Which sometimes leads to me
    start typing a new filename and by it loosing the suggested filename, and ofcourse the the extension too.

    I wasn't trying to add a _specific_ new type (such as .css); I was
    wondering if there was any way to add a _generic_ "new file" to the
    list (of things it can create).

    Hmmm... The last time I tried a similar thing it worked, but the OS was
    still looking for the suggested filename (so it could hi-lite it in the file-browser). iow, it left something to be desired. :-\

    The whole "trick" was to, in the registry, replace the "filename" value with the template-file name with a "command" value pointing to some kind of executable (in my case some VBScript) which took the suggested path &
    filename (provided to the executable/script as "%1"), stripped the filename, appended a new filename and created it.

    Not the best solution, so I never used it.

    To be honest, I never thought about creating a file without an extension, as
    it was, under XP, too easy to delete the extension.

    Regards,
    Rudy Wieser

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From J. P. Gilliver@21:1/5 to R.Wieser on Tue Jul 29 01:37:01 2025
    XPost: comp.internet.services.video.youtube

    On 2025/7/28 21:18:49, R.Wieser wrote:
    J. P. ,

    On my machine that is what happens by default : if you forget the
    extension none is used. When you use an extension than that one
    is used. In both cases you get a warning though

    I think we're talking about different things. I'm talking about
    right-clicking in a folder (in File Explorer), and selecting New:

    Don't worry, we are talking about the same thing.

    You can't "forget" the extension - when you
    select one of the options, it preloads the extension (e. g. if you
    select Text Document, it creates "New Text Document.txt", with
    the part before the dot highlighted for you to tye-replace.

    Well, that is different from what happens on my XP machine - there the whole name (including the extension) is hi-lited. Which sometimes leads to me start typing a new filename and by it loosing the suggested filename, and ofcourse the the extension too.

    I'd forgotten that was how it used to work.>
    I wasn't trying to add a _specific_ new type (such as .css); I was
    wondering if there was any way to add a _generic_ "new file" to the
    list (of things it can create).

    []
    To be honest, I never thought about creating a file without an extension, as it was, under XP, too easy to delete the extension.

    []
    Yes, when you become aware that it is only too easy to do something by
    mistake, you get sensitised to it and don't often do it!

    I wasn't after a way to create an extensionless file - only to avoid _predefined_ extensions, so I could make an arbitrary one without having
    to accept the warning message.

    The only time I've dealt with an extensionless file (apart from some
    _really_ old ones - 1990s or earlier?, from before standard extensions
    became a thing! - is the hosts file: see threads here passim.

    --
    J. P. Gilliver. UMRA: 1960/<1985 MB++G()AL-IS-Ch++(p)Ar@T+H+Sh0!:`)DNAf

    Alcohol is way ahead of cocaine as the world's deadliest drug, hastening
    around three million people per year into their graves (cocaine and
    heroin and crystal meth account for around half a million annually).
    Revd Richard Coles, RT 2021/7/3-9

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From R.Wieser@21:1/5 to All on Tue Jul 29 09:10:50 2025
    XPost: comp.internet.services.video.youtube

    J. P. ,

    I wasn't trying to add a _specific_ new type (such as .css); I was
    wondering if there was any way to add a _generic_ "new file" to the
    list (of things it can create).

    In that case the "trick" with the "command" value should work. In my case I would use some VBScript and add an inputbox to enter the new name in.

    The downside that the new file doesn't get hi-lited still applies tho.

    The only time I've dealt with an extensionless file (apart from some
    _really_ old ones - 1990s or earlier?, from before standard extensions
    became a thing! - is the hosts file: see threads here passim.

    Same here - although a quick check just now shows there are a number of them
    in the Windows folder-tree (none for the user though).

    Regards,
    Rudy Wieser

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From R.Wieser@21:1/5 to All on Tue Jul 29 10:03:25 2025
    XPost: comp.internet.services.video.youtube

    J.P. ,

    I wasn't trying to add a _specific_ new type (such as .css); I was
    wondering if there was any way to add a _generic_ "new file" to
    the list (of things it can create).

    I could not drop the issue, and googled for how it could/would work on XP.
    The first result was this one :

    https://superuser.com/questions/1632295/creating-a-file-with-no-extension-with-right-click-on-windows-10

    :-)

    The whole "trick" seems to be to press ctrl-A to select the whole filename.

    Regards,
    Rudy Wieser

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From R.Wieser@21:1/5 to All on Tue Jul 29 10:15:28 2025
    XPost: comp.internet.services.video.youtube

    J.P. ,

    Another possibility (likely doesn't pop up the "changing extension" confirmation dialog) :

    https://stackoverflow.com/questions/77233980/how-to-creating-a-new-file-context-menu-for-blank-no-extension-file-or-your-ow

    Notice the "NoExtension" entry.

    Regards,
    Rudy Wieser

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Paul@21:1/5 to Chris on Tue Jul 29 12:06:09 2025
    On Tue, 7/29/2025 2:26 AM, Chris wrote:


    "file" uses the magic number to identify the file type. It doesn't care
    what the extension is. Linux overall also doesn't generally care either.

    On linux I would use the 'touch' command to create whatever empty new file
    I wanted. No need for a gui or mouse clicks.

    This is a wish to fit the activity into a shellex menu.

    There are some people here, with quite elaborate customization.
    Their screen looks like the panel from the 747.

    Paul

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From J. P. Gilliver@21:1/5 to R.Wieser on Tue Jul 29 18:46:08 2025
    XPost: comp.internet.services.video.youtube

    On 2025/7/29 8:10:50, R.Wieser wrote:
    J. P. ,

    []

    The only time I've dealt with an extensionless file (apart from some
    _really_ old ones - 1990s or earlier?, from before standard extensions
    became a thing! - is the hosts file: see threads here passim.

    Same here - although a quick check just now shows there are a number of them in the Windows folder-tree (none for the user though).

    Regards,
    Rudy Wieser



    Just out of curiosity - how did you find that out? Looking for no
    extensions sounds challenging!

    dir /s *.

    maybe?
    --
    J. P. Gilliver. UMRA: 1960/<1985 MB++G()AL-IS-Ch++(p)Ar@T+H+Sh0!:`)DNAf

    Alcohol is way ahead of cocaine as the world's deadliest drug, hastening
    around three million people per year into their graves (cocaine and
    heroin and crystal meth account for around half a million annually).
    Revd Richard Coles, RT 2021/7/3-9

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From knuttle@21:1/5 to J. P. Gilliver on Tue Jul 29 13:58:27 2025
    XPost: comp.internet.services.video.youtube

    On 07/29/2025 1:46 PM, J. P. Gilliver wrote:
    On 2025/7/29 8:10:50, R.Wieser wrote:
    J. P. ,

    []

    The only time I've dealt with an extensionless file (apart from some
    _really_ old ones - 1990s or earlier?, from before standard extensions
    became a thing! - is the hosts file: see threads here passim.

    Same here - although a quick check just now shows there are a number of them >> in the Windows folder-tree (none for the user though).

    Regards,
    Rudy Wieser



    Just out of curiosity - how did you find that out? Looking for no
    extensions sounds challenging!

    dir /s *.

    maybe?
    If you use Thunderbird, it has always used an extensionless file for the
    bodies of the emails in a folder and a file of the same name with an
    extentions to keep track of the individual messages. ie Folder in the
    current version named 5K RUN = two folders, 5K RUN. / 5K RUN.msf.

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From R.Wieser@21:1/5 to All on Tue Jul 29 20:21:36 2025
    XPost: comp.internet.services.video.youtube

    J.P. ,

    Same here - although a quick check just now shows there are a number
    of them in the Windows folder-tree (none for the user though).

    Just out of curiosity - how did you find that out? Looking for no
    extensions sounds challenging!

    dir /s *.

    maybe?

    Pretty-much, yes. :-)

    dir /s /b /a-d *.

    The "/b" to get whole filepaths, the "/a-d" to get rid of the
    subdirectories.

    Regards,
    Rudy Wieser

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From knuttle@21:1/5 to R.Wieser on Tue Jul 29 15:20:47 2025
    XPost: comp.internet.services.video.youtube

    On 07/29/2025 2:21 PM, R.Wieser wrote:
    J.P. ,

    Same here - although a quick check just now shows there are a number
    of them in the Windows folder-tree (none for the user though).

    Just out of curiosity - how did you find that out? Looking for no
    extensions sounds challenging!

    dir /s *.

    maybe?

    Pretty-much, yes. :-)

    dir /s /b /a-d *.

    The "/b" to get whole filepaths, the "/a-d" to get rid of the
    subdirectories.

    Regards,
    Rudy Wieser


    It is amazing what you can do with the old Dos Batch file commands.
    Some years ago I worked for a company where IT tied all computer up so
    they would be secure. You could basically run approved programs and
    type from the keyboard. EXCEPT they forgot about the BATCH commands.
    I used them to create a database of some files on their system, saved me
    a lot of typing.

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From R.Wieser@21:1/5 to All on Tue Jul 29 21:47:03 2025
    XPost: comp.internet.services.video.youtube

    Knuttle,

    It is amazing what you can do with the old Dos Batch file commands.

    Command line commands actually. But yes, they also worked in batch files.
    :-)

    Some years ago I worked for a company where IT tied all computer up so
    they would be secure. You could basically run approved programs and type from the keyboard. EXCEPT they forgot about the BATCH commands.

    Don't blame them (to harshely). Even MS has dropped the ball in that : I've still got the instructions with which to bypass W98 login procedure - and
    its surprisingly easy (using their OS against them).

    I used them to create a database of some files on their system, saved me a lot of typing.

    That makes me remember this story :

    https://thedailywtf.com/articles/Classic-WTF-The-Indexer

    :-)

    Regards,
    Rudy Wieser

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From J. P. Gilliver@21:1/5 to R.Wieser on Tue Jul 29 22:38:35 2025
    XPost: comp.internet.services.video.youtube

    On 2025/7/29 20:47:3, R.Wieser wrote:
    Knuttle,

    It is amazing what you can do with the old Dos Batch file commands.

    Command line commands actually. But yes, they also worked in batch files. :-)

    Yes, I admired that knowledge of dir's switches!

    []

    https://thedailywtf.com/articles/Classic-WTF-The-Indexer

    []

    I found that depressingly believable.
    --
    J. P. Gilliver. UMRA: 1960/<1985 MB++G()AL-IS-Ch++(p)Ar@T+H+Sh0!:`)DNAf

    This was before we knew that a laboratory rat, if experimented upon,
    will develop cancer. [Quoted by] Anne ([email protected]), 1997-1-29

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From J. P. Gilliver@21:1/5 to R.Wieser on Tue Jul 29 22:51:54 2025
    XPost: comp.internet.services.video.youtube

    On 2025/7/29 9:3:25, R.Wieser wrote:
    J.P. ,

    I wasn't trying to add a _specific_ new type (such as .css); I was
    wondering if there was any way to add a _generic_ "new file" to
    the list (of things it can create).

    I could not drop the issue, and googled for how it could/would work on XP. The first result was this one :

    https://superuser.com/questions/1632295/creating-a-file-with-no-extension-with-right-click-on-windows-10

    :-)

    The whole "trick" seems to be to press ctrl-A to select the whole filename.

    Regards,
    Rudy Wieser


    That method - running the file through a text editor so you can use
    quote marks when saving - could corrupt some non-text files. The better
    method is to ensure "show extensions [even] for known filetypes" is
    selected, then you can edit including the extensions without running the
    files through anything.

    That should have been the default for that option for decades, ever
    since black hats started to use double extensions to hide malware.
    --
    J. P. Gilliver. UMRA: 1960/<1985 MB++G()AL-IS-Ch++(p)Ar@T+H+Sh0!:`)DNAf

    Of course some of it [television] is bad. But some of everything is bad
    - books, music, family ... - Melvyn Bragg, RT 2017/7/1-7

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Paul@21:1/5 to R.Wieser on Tue Jul 29 22:02:15 2025
    XPost: comp.internet.services.video.youtube

    On Tue, 7/29/2025 3:47 PM, R.Wieser wrote:
    Knuttle,

    It is amazing what you can do with the old Dos Batch file commands.

    Command line commands actually. But yes, they also worked in batch files. :-)

    Some years ago I worked for a company where IT tied all computer up so
    they would be secure. You could basically run approved programs and type
    from the keyboard. EXCEPT they forgot about the BATCH commands.

    Don't blame them (to harshely). Even MS has dropped the ball in that : I've still got the instructions with which to bypass W98 login procedure - and
    its surprisingly easy (using their OS against them).

    I used them to create a database of some files on their system, saved me a >> lot of typing.

    That makes me remember this story :

    https://thedailywtf.com/articles/Classic-WTF-The-Indexer

    :-)

    Regards,
    Rudy Wieser



    One thing about "dir", is it is hella-fast as code goes.
    Other ways of enumerating a file tree, don't go that fast.

    The "dir" thing can read the $MFT at an equivalent speed
    of 2GB/sec. Which is pretty well the top speed of any userspace
    stuff on the machine here. It's possible irfanview runs
    that fast, when loading an image (I have the odd test image
    that is 10GB in size). My storage won't go much faster than that,
    depending on activities on the machine at the time.

    Paul

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From R.Wieser@21:1/5 to All on Wed Jul 30 08:57:25 2025
    XPost: comp.internet.services.video.youtube

    J.P. ,

    Command line commands actually. But yes, they also worked in batch
    files. :-)

    Yes, I admired that knowledge of dir's switches!

    :-) I just had to remember *one* thing : if I had no clue (or forgotten)
    what a command does than I just needed to type its name and than "/?"
    (without the double-quotes). Most of the time it than showed a "help" page with all its arguments switches.

    Under XP it even works for the command-shell itself : "command /?" or "cmd
    /?".


    https://thedailywtf.com/articles/Classic-WTF-The-Indexer

    I found that depressingly believable.

    Indeed. Which is why I saved the story on my 'puter (could not chance it to disappear).

    Regards,
    Rudy Wieser

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From R.Wieser@21:1/5 to All on Wed Jul 30 09:42:03 2025
    XPost: comp.internet.services.video.youtube

    J.P. ,

    https://superuser.com/questions/1632295/creating-a-file-with-no-extension-with-right-click-on-windows-10

    The whole "trick" seems to be to press ctrl-A to select the whole
    filename.

    That method - running the file through a text editor so you can use
    quote marks when saving

    Thats not what I tried to suggest.

    You mentioned that, when creating a new document, you could edits the
    filename itself, but not the extension. At that moment try pressing ctrl-A
    and see if that results in the extension also getting selected for editing.

    ... but reading on I think I made an assumption which has made a fool outof
    me :

    The better method is to ensure "show extensions [even] for known
    filetypes"
    is selected, then you can edit including the extensions without running
    the
    files through anything.

    I /assumed/ that you saw, after creating a new document, something like "[filename].ext", with only the part beween the "[" and "]" being editable. Which, from my POV, didn't seem too strange, as most people will want to
    keep the extension when changing the filename.

    The ctrl-a "trick" was, I assumed, to change the above into "[filename.ext]" (making the full filename editable).

    But yes, its quite possible that me having changed the OS configuration when
    I installed it to always show extensions just /might/ have something to do
    with me always seeing and being able to edit the full filename. <whistle>

    That should have been the default for that option for decades, ever
    since black hats started to use double extensions to hide malware.

    I do not agree with you there.

    Most users are just that, *users*. They know which icon they need to click
    on their desktop, but often no more than that. They really need to be protected against their own absense of knowledge (the same reason for why certain OS related files are hidden). Making sure that they can change a filename but not inadvertedly throw the extension away (after which the icon changes and they cannot find the file back and/or double-click it to open
    it) is one of those protections.

    Remember all those stories about users which tried to "clean up" their
    'puters by throwing all files away they did not recognise - and than
    complained that their 'puter would not start anymore ? Yeah
    that happens when you "clean up" the OS folder that way. :-)

    But for "power"-users ? Certainly. But they are knowledgable enough to disable such hand-holding protections in the configuration just after having installed the OS. As yours truly has done, and absolutily forgotten about. :-|

    As for the "black hat" example you've given ? AFAIK the OS tries to warn
    you with a popup when you try to start downloaded executables. What does
    the run-of-the-mill user ? Figure out which choice makes the popup go away and than blindly apply it, without even reading what it tries to tell them (yeah, I have been shoulder-surfing a number of such users, just to figure
    out what went "wrong" on their machine - a popup comes up and within half a second its been clicked away). :-\

    As such I expect one of the future Windows versions to have a default configuration that prohibits the user from running any executable (of any
    kind) that has somehow been copied into it (downloaded, thumbdrive, etc).

    Regards,
    Rudy Wieser

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From R.Wieser@21:1/5 to All on Wed Jul 30 09:54:05 2025
    XPost: comp.internet.services.video.youtube

    Paul,

    One thing about "dir", is it is hella-fast as code goes.
    Other ways of enumerating a file tree, don't go that fast.

    I have no idea which internal tricks the "dir" command uses to become that fast*, but do remember that the commandline "dir" doesn't sort. It just
    shows the files in order of how they appear in the filesystem. Most Windows oriented "dir" methods will sort on the filename.

    * it could just iterate over the records in a retrieved raw cluster,
    bypassing the API the rest of us have to use.

    Also, I've written directory traversal code for both DOS as well as Windows, and if I did not output anything it was always quite fast. iow, the
    bottleneck was more often than not the storing of the retrieved data
    somewhere (screen, list/treeview, file).

    Regards,
    Rudy Wieser

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Philip Herlihy@21:1/5 to All on Wed Jul 30 14:24:13 2025
    XPost: comp.internet.services.video.youtube

    In article <106b8gk$2rau6$[email protected]>, [email protected]d says...

    Knuttle,

    It is amazing what you can do with the old Dos Batch file commands.

    ...
    That makes me remember this story :

    https://thedailywtf.com/articles/Classic-WTF-The-Indexer


    You could do even more with Unix shell-scripting - presumably still
    availablein Linux, and something similar's available with PowerShell
    (never learned either as it happens).

    Years ago (mid- 90s) the head of my department called me into his
    office. Had a project for me, likely to last 6m or so. He described it
    - a way of grooming a live feed so that stats could be displayed on one
    of these new-fangled "web pages". Realisation dawned as he spoke. I
    asked if I could come back to him in an hour's time. He was puzzled,
    but agreed.

    An hour later I explained that I'd assembled a series of shell-script
    fragments that I'd been gradually accumulating over the last year into a utility that would do exactly what he wanted, crucially using the
    relational "JOIN" script command. It would need a little tidying up in
    terms of the exact display, but it was working. Right now, at my desk upstairs.

    He just didn't get it. He said he would "drop by" and take a look, but
    he never did. And a week later, one of my colleagues was given the same project. He was still trying to write C++ code six months later. Yet
    within an hour of being asked, I'd had a working prototype running on my screen. Didn't do me any good, actually. That was meant to be a plum
    project, and I was overlooked after that. (I left.)

    In another role, I'd come in one morning to find my then boss sizzling
    over his keyboard. He'd been given a large (!) file of data including a
    "code" for a location in a vast network. Unfortunately the other data
    that was to be used had the code formatted very slightly differently -
    the human eye could make the translation trivially, but matching it electronically was impossible, it seemed. He'd come in just after dawn
    and had been working in a text editor manually changing the codes for
    two hours by the time I arrived. The progress indicator still showed
    0%.

    "Would you like me to do that for you?" I asked. He practically kicked
    his chair down the hall. I got him to explain the exact naming
    convention, and spent ten minutes studying both files of data, and
    writing a shell "pipeline" using "SED", the only utility capable both of "regular expressions" and handling a file of arbitrary size. I closed
    his edit session (cheekily telling it not to bother saving changes) and
    ran my script. It ran for ten minutes, and fixed every single code.

    Then there was the project based on an object-oriented database (which
    didn't seem to work after a month's hard work on it) which I replaced
    with a shell-script I'd written in two hours for a customer demo which
    had been sprung on me at 24 hours' notice. My then boss subsequently
    went off into rhetorical flights about how this COULD NOT HAVE BEEN
    ACHIEVED in just one month without using "advanced programming
    techniques" like the latest object-oriented database. I only told him afterwards.

    DOS scripting never had the power or fluency of Unix shell-scripting,
    but although I find the "look" of PowerShell rather off-putting I think
    it very likely that PS could do all this - it's just a shame I've never
    had any reason to learn it. But if you're a Linux user, check to see if
    SED and AWK and JOIN (etc) are still available. If so, you're sitting
    on some real data processing power there.

    --
    Phil, London

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Paul@21:1/5 to Philip Herlihy on Wed Jul 30 09:55:23 2025
    XPost: comp.internet.services.video.youtube

    On Wed, 7/30/2025 9:24 AM, Philip Herlihy wrote:
    In article <106b8gk$2rau6$[email protected]>, [email protected]d says...

    Knuttle,

    It is amazing what you can do with the old Dos Batch file commands.

    ...
    That makes me remember this story :

    https://thedailywtf.com/articles/Classic-WTF-The-Indexer


    You could do even more with Unix shell-scripting - presumably still availablein Linux, and something similar's available with PowerShell
    (never learned either as it happens).

    Years ago (mid- 90s) the head of my department called me into his
    office. Had a project for me, likely to last 6m or so. He described it
    - a way of grooming a live feed so that stats could be displayed on one
    of these new-fangled "web pages". Realisation dawned as he spoke. I
    asked if I could come back to him in an hour's time. He was puzzled,
    but agreed.

    An hour later I explained that I'd assembled a series of shell-script fragments that I'd been gradually accumulating over the last year into a utility that would do exactly what he wanted, crucially using the
    relational "JOIN" script command. It would need a little tidying up in
    terms of the exact display, but it was working. Right now, at my desk upstairs.

    He just didn't get it. He said he would "drop by" and take a look, but
    he never did. And a week later, one of my colleagues was given the same project. He was still trying to write C++ code six months later. Yet
    within an hour of being asked, I'd had a working prototype running on my screen. Didn't do me any good, actually. That was meant to be a plum project, and I was overlooked after that. (I left.)

    In another role, I'd come in one morning to find my then boss sizzling
    over his keyboard. He'd been given a large (!) file of data including a "code" for a location in a vast network. Unfortunately the other data
    that was to be used had the code formatted very slightly differently -
    the human eye could make the translation trivially, but matching it electronically was impossible, it seemed. He'd come in just after dawn
    and had been working in a text editor manually changing the codes for
    two hours by the time I arrived. The progress indicator still showed
    0%.

    "Would you like me to do that for you?" I asked. He practically kicked
    his chair down the hall. I got him to explain the exact naming
    convention, and spent ten minutes studying both files of data, and
    writing a shell "pipeline" using "SED", the only utility capable both of "regular expressions" and handling a file of arbitrary size. I closed
    his edit session (cheekily telling it not to bother saving changes) and
    ran my script. It ran for ten minutes, and fixed every single code.

    Then there was the project based on an object-oriented database (which
    didn't seem to work after a month's hard work on it) which I replaced
    with a shell-script I'd written in two hours for a customer demo which
    had been sprung on me at 24 hours' notice. My then boss subsequently
    went off into rhetorical flights about how this COULD NOT HAVE BEEN
    ACHIEVED in just one month without using "advanced programming
    techniques" like the latest object-oriented database. I only told him afterwards.

    DOS scripting never had the power or fluency of Unix shell-scripting,
    but although I find the "look" of PowerShell rather off-putting I think
    it very likely that PS could do all this - it's just a shame I've never
    had any reason to learn it. But if you're a Linux user, check to see if
    SED and AWK and JOIN (etc) are still available. If so, you're sitting
    on some real data processing power there.

    --
    Phil, London


    AWK is what I use for text processing. I have the AWK book, from the inventors of the language, printed in 1988. But the book is not necessary, because
    of the PDF manual that comes with GAWK (which came later in time). You can
    make system calls from there, which gives you some elements of scripting,
    with perhaps a bit easier syntax.

    This one has Windows line endings, and is version 3.1.6 .

    https://gnuwin32.sourceforge.net/packages/gawk.htm

    If I switch to Bash shell, the Linux there has Gawk 4, but you
    need a two line stanza to fix the line endings (because it has
    Linux line endings). On only one occasion, I had the windows 3.1.6
    version crash, while processing a 10GB text file. I took it over
    to the Gawk 4 one, and the script ran without a problem.

    The doc link would get you the PDF file (after you unpack
    the ZIP that the site delivers).

    https://gnuwin32.sourceforge.net/downlinks/gawk-doc-zip.php

    SED is more powerful, in that you can handle some pretty nasty
    messes in files with it. But then the syntax is also a handful.

    AWK has the limitation it's not a UTF-8 thing, it works with
    ANSI text most directly. You have to be more careful on
    modern Windows, with your Notepad and the saving modes,
    to not make disaster-materials for your AWK run.

    Paul

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Paul@21:1/5 to R.Wieser on Wed Jul 30 10:02:39 2025
    XPost: comp.internet.services.video.youtube

    On Wed, 7/30/2025 3:42 AM, R.Wieser wrote:

    But yes, its quite possible that me having changed the OS configuration when I installed it to always show extensions just /might/ have something to do with me always seeing and being able to edit the full filename. <whistle>

    Maybe we should take a poll and see how many people leave that
    blasted "hide the extension" setting, when installing Windows.

    That's one of the first things you "fix" after installation.

    You cannot safely or efficiently run with the default setting.
    The first example, is what you find with the Hide The Extension in File Explorer Options.

    jugofwine (some little icon you can't make out)
    jugofwine (some little icon which is not the same as the other one)

    versus after the user corrects that setting

    jugofwine.txt
    jugofwine.jpg

    When you can't make out the icon, the extension adds the distinction required.

    Paul

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From R.Wieser@21:1/5 to All on Wed Jul 30 17:04:57 2025
    XPost: comp.internet.services.video.youtube

    Paul,

    You cannot safely or efficiently run with the default setting.

    I agree with the first, and it depends to the second.

    jugofwine (some little icon you can't make out)
    ...
    jugofwine.txt

    jugofwine (some little icon which is not the same as the other one)
    ...
    jugofwine.jpg

    On my XP machine both show quite recognisable icons in most views. Enough
    of a distinction not to mix them up.

    But you are ofcourse aware that its /the users fault/ for having given them both the same names. They should have been wiser than that (yes, the same
    user who dismisses warnings without reading them) :-p

    When you can't make out the icon, the extension adds the distinction required.

    True. Or just do what the comon user does : double-click it and see what happens. If what happens is not what is needed just close ... the whatever
    and double-click the other one. :-)

    Though one rather nasty drawback of not displaying the extension is that an executable can be given any icon a malware writer desires. Including the one indicating a picture. Double-click that "picture" and you're f*cked. :-(

    Regards,
    Rudy Wieser

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From knuttle@21:1/5 to Philip Herlihy on Wed Jul 30 13:44:18 2025
    XPost: comp.internet.services.video.youtube

    On 07/30/2025 9:24 AM, Philip Herlihy wrote:
    In article <106b8gk$2rau6$[email protected]>, [email protected]d says...

    Knuttle,

    It is amazing what you can do with the old Dos Batch file commands.

    ...
    That makes me remember this story :

    https://thedailywtf.com/articles/Classic-WTF-The-Indexer


    You could do even more with Unix shell-scripting - presumably still availablein Linux, and something similar's available with PowerShell
    (never learned either as it happens).

    Years ago (mid- 90s) the head of my department called me into his
    office. Had a project for me, likely to last 6m or so. He described it
    - a way of grooming a live feed so that stats could be displayed on one
    of these new-fangled "web pages". Realisation dawned as he spoke. I
    asked if I could come back to him in an hour's time. He was puzzled,
    but agreed.

    An hour later I explained that I'd assembled a series of shell-script fragments that I'd been gradually accumulating over the last year into a utility that would do exactly what he wanted, crucially using the
    relational "JOIN" script command. It would need a little tidying up in
    terms of the exact display, but it was working. Right now, at my desk upstairs.

    He just didn't get it. He said he would "drop by" and take a look, but
    he never did. And a week later, one of my colleagues was given the same project. He was still trying to write C++ code six months later. Yet
    within an hour of being asked, I'd had a working prototype running on my screen. Didn't do me any good, actually. That was meant to be a plum project, and I was overlooked after that. (I left.)

    In another role, I'd come in one morning to find my then boss sizzling
    over his keyboard. He'd been given a large (!) file of data including a "code" for a location in a vast network. Unfortunately the other data
    that was to be used had the code formatted very slightly differently -
    the human eye could make the translation trivially, but matching it electronically was impossible, it seemed. He'd come in just after dawn
    and had been working in a text editor manually changing the codes for
    two hours by the time I arrived. The progress indicator still showed
    0%.

    "Would you like me to do that for you?" I asked. He practically kicked
    his chair down the hall. I got him to explain the exact naming
    convention, and spent ten minutes studying both files of data, and
    writing a shell "pipeline" using "SED", the only utility capable both of "regular expressions" and handling a file of arbitrary size. I closed
    his edit session (cheekily telling it not to bother saving changes) and
    ran my script. It ran for ten minutes, and fixed every single code.

    Then there was the project based on an object-oriented database (which
    didn't seem to work after a month's hard work on it) which I replaced
    with a shell-script I'd written in two hours for a customer demo which
    had been sprung on me at 24 hours' notice. My then boss subsequently
    went off into rhetorical flights about how this COULD NOT HAVE BEEN
    ACHIEVED in just one month without using "advanced programming
    techniques" like the latest object-oriented database. I only told him afterwards.

    DOS scripting never had the power or fluency of Unix shell-scripting,
    but although I find the "look" of PowerShell rather off-putting I think
    it very likely that PS could do all this - it's just a shame I've never
    had any reason to learn it. But if you're a Linux user, check to see if
    SED and AWK and JOIN (etc) are still available. If so, you're sitting
    on some real data processing power there.

    --
    Phil, London
    I could be wrong but as I remember Powershell was just a CMD that was
    giving administrative privileges. In the current Windows 11 they are
    called Terminal and Terminal (admin). both accept the old DOS commands
    just differing in what they can access.

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Mark Lloyd@21:1/5 to J. P. Gilliver on Wed Jul 30 18:15:47 2025
    XPost: comp.internet.services.video.youtube

    On Tue, 29 Jul 2025 22:51:54 +0100, J. P. Gilliver wrote:

    On 2025/7/29 9:3:25, R.Wieser wrote:


    [snip]

    That should have been the default for that option for decades, ever
    since black hats started to use double extensions to hide malware.

    Do you mean something like this?

    info.txt.exe

    That's not really "double extension". The extension is .exe, but Windows
    (by default) makes it look like .txt but that is not an extension (which explains why its not hidden too). Click on the file and Windows knows the extension is .exe.

    BTW, I always turn that lying option off.

    --
    Mark Lloyd
    http://notstupid.us/

    "To me, faith is not better because it is atheistic rather than
    theistic. I am an atheist because of a *lack* of faith, *not* because of
    a different faith." [Russell Turpin on alt.atheism]

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From J. P. Gilliver@21:1/5 to R.Wieser on Wed Jul 30 21:49:30 2025
    XPost: comp.internet.services.video.youtube

    On 2025/7/30 8:42:3, R.Wieser wrote:
    J.P. ,

    https://superuser.com/questions/1632295/creating-a-file-with-no-extension-with-right-click-on-windows-10

    The whole "trick" seems to be to press ctrl-A to select the whole
    filename.

    That method - running the file through a text editor so you can use
    quote marks when saving

    Thats not what I tried to suggest.

    No, not you, but one of the people in the discussion someone posted a
    link to suggested that method.


    You mentioned that, when creating a new document, you could edits the filename itself, but not the extension. At that moment try pressing ctrl-A and see if that results in the extension also getting selected for editing.

    If I did say that, it's not what I _meant_ to say. What I _meant_ to say
    is that, by default or after you've added a few bits of software, the
    "New" option in File Manager still only offer a list of predefined
    filetypes, all of which of course come with their own extension; I was wondering if there was any way to add to that list the option to add a
    new filetype with an arbitrary (or no) extension.

    Given that you _can_ only create files from the predefined list of
    types, I _can_ relatively easily edit the extension: the new filename
    appears with the before-the-dot part _highlighted_, since in most case
    people _don't_ want to change the extension, but it's easy to move the
    cursor (or whatever) to edit the extension if you want to. (At least it
    is with "hide extensions" turned off; I usually turn that off so soon
    after starting using a system that I don't know if you can edit
    extensions when hidden.)


    ... but reading on I think I made an assumption which has made a fool outof me :

    The better method is to ensure "show extensions [even] for known
    filetypes"
    is selected, then you can edit including the extensions without running
    the
    files through anything.

    I /assumed/ that you saw, after creating a new document, something like "[filename].ext", with only the part beween the "[" and "]" being editable.

    Well, only that part is _highlighted_, but you can move onto the
    extension easily enough.

    Which, from my POV, didn't seem too strange, as most people will want to
    keep the extension when changing the filename.

    The ctrl-a "trick" was, I assumed, to change the above into "[filename.ext]" (making the full filename editable).

    But yes, its quite possible that me having changed the OS configuration when I installed it to always show extensions just /might/ have something to do with me always seeing and being able to edit the full filename. <whistle>

    That should have been the default for that option for decades, ever
    since black hats started to use double extensions to hide malware.

    I do not agree with you there.

    Most users are just that, *users*. They know which icon they need to click on their desktop, but often no more than that. They really need to be protected against their own absense of knowledge (the same reason for why certain OS related files are hidden). Making sure that they can change a filename but not inadvertedly throw the extension away (after which the icon changes and they cannot find the file back and/or double-click it to open
    it) is one of those protections.

    They need to be protected against inadvertently changing extensions,
    granted. That's why, if you have hiding turned off (i. e. extensions
    visible) and you select rename (e. f. with F2), only the name part is _highlighted_.

    But they also need protecting against malware with "double extensions",
    such as .doc.exe (or perhaps .txt.com more likely when this practice
    started). Such malware would, if extensions are hidden, just appear as
    .doc or .txt files; sure, the user will have a moment of puzzlement at
    seeing those extensions when s/he thought they'd turned them off, but
    might well still double-click them. I think actually running malware is
    more dangerous than just changing an extension - the latter can usually
    be fixed by asking someone more experienced if they can't find the file,
    but the former might do goodness knows what, certainly nothing benign or
    its writer wouldn't have done it.>
    Remember all those stories about users which tried to "clean up" their 'puters by throwing all files away they did not recognise - and than complained that their 'puter would not start anymore ? Yeah
    that happens when you "clean up" the OS folder that way. :-)

    Yes. And those stories of all those users who clicked on (say)
    sharapova.jpg (I think that was the name) thinking they'd see a picture
    of a tennis player.>
    But for "power"-users ? Certainly. But they are knowledgable enough to disable such hand-holding protections in the configuration just after having installed the OS. As yours truly has done, and absolutily forgotten about. :-|

    As for the "black hat" example you've given ? AFAIK the OS tries to warn you with a popup when you try to start downloaded executables. What does

    Yes, it does these days. (Though trivial to bypass by moving the
    executables from somewhere other than the internet. But probably saves
    _some_ malware from being run, if it wasn't for ...)

    the run-of-the-mill user ? Figure out which choice makes the popup go away and than blindly apply it, without even reading what it tries to tell them

    ... that.) I used to have a quote something like "The difficulty in
    making things idiot-proof, is that idiots can be so damn ingenious."

    (yeah, I have been shoulder-surfing a number of such users, just to figure out what went "wrong" on their machine - a popup comes up and within half a second its been clicked away). :-\

    Very true. And not just they, but we do it too - the "ohnosecond"
    between dismissing and thinking "_what_ did that say?".


    As such I expect one of the future Windows versions to have a default configuration that prohibits the user from running any executable (of any kind) that has somehow been copied into it (downloaded, thumbdrive, etc).

    We sure seem to be going that way. The eternal nannying increase is one
    of the main reasons I hate "up"grading!>
    Regards,
    Rudy Wieser


    John
    --
    J. P. Gilliver. UMRA: 1960/<1985 MB++G()AL-IS-Ch++(p)Ar@T+H+Sh0!:`)DNAf

    Heaven forbid today's audience should feel bombarded with information or
    worse, lectured. Dont'scare the horses by waving facts around.
    - David Butcher, RT 2014/11/29-12/5

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Paul@21:1/5 to knuttle on Wed Jul 30 23:33:18 2025
    XPost: comp.internet.services.video.youtube

    On Wed, 7/30/2025 1:44 PM, knuttle wrote:

    I could be wrong but as I remember Powershell was just a CMD that
    was giving administrative privileges.  In the current Windows 11 they are called Terminal and Terminal (admin).  both accept the old DOS commands
    just differing in what they can access.

    MSDOS - Close to the hardware, Little protection for the hardware,
    "original" shell commands. I don't think there is a Ring0 and a Ring3
    for this environment. Some of the commands use raw addresses.
    (Raw *physical* addresses, not the virtual ones used elsewhere.)

    Command Prompt - Relies on a separate OS. Uses NTVDM for runtime.
    MSDOS commands are "emulated", rather than being
    direct to hardware. You will be frequently told "this
    program only works properly in MSDOS", to remind you
    that Command Prompt is not DOSBOX. It's a facade.

    PowerShell - The same degree of isolation as the Command Prompt, but
    with a "new" programming language and schema. It resorts to
    gobs or red text on error. If you run an applet and provide too
    few operands, Powershell will ask you for values for the missing
    ones (annoying!). Command Prompt does not do that. PowerShell
    has tab completion like tcsh. Type something in Powershell,
    poke the tab key multiple times and see as it offers suggestions.

    In Linux or Unix, you might have several shells. We don't insult them by claiming
    one is executing exactly the same commands as the others. They're quite different
    at the detail level.

    /bin/sh Bourne shell https://en.wikipedia.org/wiki/Bourne_shell
    /bin/csh C Shell https://en.wikipedia.org/wiki/C_shell
    /bin/tcsh C shell with Tab Completion https://en.wikipedia.org/wiki/Tcsh

    While the Windows shells can have *some* similarities

    dir # cmd.exe
    dir # powershell.exe

    the support for dir on powershell, is similar to its half assed support for ls.

    dir /ah # cmd.exe (works)
    dir /ah # powershell.exe (Uh oh, doesn't work, now we are learning something...)

    The dir on Powershell, is an instance of "Get-ChildItem" and it does not
    accept the same arguments. So rather than being a custom written "dir",
    it is an alias of some kind for "Get-ChildItem". This is a compensation for
    the muscle-memory of the user community, who would be typing "dir" and expecting output like they were typing "ls" on some other systems. But it is not really dir, it's just a tasty label affixed to "a distant approximation"
    to the command.

    If I type "ls" in Powershell, it works just as well as typing "dir".
    it uses the self-same "Get-ChildItem". If you slap too many arguments
    after the "ls" letters (which stand for listdir), the command fails
    and you get red colored text.

    ls # This never worked in cmd.exe so we expect an error. It's like testing water is wet.
    ls # Works as well as "dir" does in Powershell. Would not accept -algtR

    So like the Bourne shell example, shells evolve, different people take
    a shot at writing them. The language may be procedural, but it can
    have some differences. The syntax for a for loop could be quite
    different. Powershell has "filter behavior" when piping output from
    one applet to another applet (a power user feature, converts gobs of text
    into specific terse words).

    I don't know enough Powershell to fill a thimble :-) But, I use my experience to note it's an evolution, someone took a stab at designing a language for
    it. And they deposited a few "aliases" in it, to fool you into
    thinking that was a real "dir" they offered :-) Well, I was fooled too,
    until I did this and it failed. This was a little splash of cold water.

    dir /ah # Powershell. Oops. No hidden items for you!

    dir /? # Help option in Command Prompt
    dir -? # May offer help in Powershell (you *really* should try this one, what an eyeful!)
    # I only learned this a few days ago, and me typing it out helps reinforce it :-)

    They've made other kinds of "fool you" stuff. Like maybe "wget" is
    an alias for some network thing they wrote.

    *******

    One of the better teaching aids, is when someone makes a "programming card" with columns for each shell, and what command would be required as an equivalent for each shell. For Unix, our programming card had five shells
    on it, so there were five columns with the commands, and some points in
    the table were "missing", when one of the shells had no command to do
    a certain thing. For the most part, this wasn't really necessary
    for Windows, but maybe a programmer card eventually would be a good idea.

    Paul

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Paul@21:1/5 to Mark Lloyd on Wed Jul 30 23:37:17 2025
    XPost: comp.internet.services.video.youtube

    On Wed, 7/30/2025 2:15 PM, Mark Lloyd wrote:
    On Tue, 29 Jul 2025 22:51:54 +0100, J. P. Gilliver wrote:

    On 2025/7/29 9:3:25, R.Wieser wrote:


    [snip]

    That should have been the default for that option for decades, ever
    since black hats started to use double extensions to hide malware.

    Do you mean something like this?

    info.txt.exe

    That's not really "double extension". The extension is .exe, but Windows
    (by default) makes it look like .txt but that is not an extension (which explains why its not hidden too). Click on the file and Windows knows the extension is .exe.

    BTW, I always turn that lying option off.


    That's your OPSEC showing.

    You want to see the full name, extensions and all,
    so you don't get phished.

    This is why we turn on the extensions -- "full disclosure".

    There are still tricks you can do with exotic character sets,
    so really this only alerts you to the "easy phishing". There
    are also character sequences that can be used, where only a person
    with good eyesight will detect something is wrong with the file.

    Paul

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)