Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > alt.comp.os.windows-11 > #18061 > unrolled thread
| Started by | T <T@invalid.invalid> |
|---|---|
| First post | 2025-03-29 17:03 -0700 |
| Last post | 2025-04-01 02:01 -0700 |
| Articles | 20 on this page of 80 — 16 participants |
Back to article view | Back to alt.comp.os.windows-11
what is the fastest command line copy? T <T@invalid.invalid> - 2025-03-29 17:03 -0700
Re: what is the fastest command line copy? Paul <nospam@needed.invalid> - 2025-03-29 20:43 -0400
Re: what is the fastest command line copy? T <T@invalid.invalid> - 2025-03-29 17:49 -0700
Re: what is the fastest command line copy? Andy Burns <usenet@andyburns.uk> - 2025-03-30 06:55 +0000
Re: what is the fastest command line copy? Stan Brown <the_stan_brown@fastmail.fm> - 2025-03-31 12:08 -0700
Re: what is the fastest command line copy? Andy Burns <usenet@andyburns.uk> - 2025-03-31 20:35 +0100
Re: what is the fastest command line copy? Stan Brown <the_stan_brown@fastmail.fm> - 2025-03-31 13:35 -0700
Re: what is the fastest command line copy? Dual Boot Windows <invalid@invalid.invalid> - 2025-03-31 02:12 +0100
Re: what is the fastest command line copy? Steve Hayes <hayesstw@telkomsa.net> - 2025-03-31 04:43 +0200
Re: what is the fastest command line copy? Paul <nospam@needed.invalid> - 2025-03-31 00:47 -0400
Re: what is the fastest command line copy? Steve Hayes <hayesstw@telkomsa.net> - 2025-03-31 11:06 +0200
Re: what is the fastest command line copy? Stan Brown <the_stan_brown@fastmail.fm> - 2025-03-31 12:10 -0700
Re: what is the fastest command line copy? "Jonathan N. Little" <lws4art@gmail.com> - 2025-04-01 18:56 -0400
Re: what is the fastest command line copy? Newyana2 <newyana@invalid.nospam> - 2025-03-31 08:21 -0400
Re: what is the fastest command line copy? "R.Wieser" <address@is.invalid> - 2025-03-31 15:47 +0200
Re: what is the fastest command line copy? Newyana2 <newyana@invalid.nospam> - 2025-03-31 10:54 -0400
Re: what is the fastest command line copy? Andy Burns <usenet@andyburns.uk> - 2025-03-31 15:59 +0100
Re: what is the fastest command line copy? "R.Wieser" <address@is.invalid> - 2025-03-31 17:32 +0200
Re: what is the fastest command line copy? Steve Hayes <hayesstw@telkomsa.net> - 2025-04-01 07:00 +0200
Re: what is the fastest command line copy? "R.Wieser" <address@is.invalid> - 2025-04-01 09:11 +0200
Re: what is the fastest command line copy? Paul <nospam@needed.invalid> - 2025-04-01 03:44 -0400
Re: what is the fastest command line copy? Newyana2 <newyana@invalid.nospam> - 2025-04-01 09:26 -0400
Re: what is the fastest command line copy? Steve Hayes <hayesstw@telkomsa.net> - 2025-04-02 08:50 +0200
Re: what is the fastest command line copy? Paul <nospam@needed.invalid> - 2025-04-02 04:15 -0400
Re: what is the fastest command line copy? "R.Wieser" <address@is.invalid> - 2025-04-02 10:35 +0200
Re: what is the fastest command line copy? Paul <nospam@needed.invalid> - 2025-04-02 05:54 -0400
Re: what is the fastest command line copy? "R.Wieser" <address@is.invalid> - 2025-04-02 16:15 +0200
Re: what is the fastest command line copy? Paul <nospam@needed.invalid> - 2025-04-02 11:40 -0400
Re: what is the fastest command line copy? "R.Wieser" <address@is.invalid> - 2025-04-02 18:13 +0200
Re: what is the fastest command line copy? Paul <nospam@needed.invalid> - 2025-04-02 12:41 -0400
Re: what is the fastest command line copy? "R.Wieser" <address@is.invalid> - 2025-04-02 20:27 +0200
Re: what is the fastest command line copy? Paul <nospam@needed.invalid> - 2025-04-03 03:22 -0400
Re: what is the fastest command line copy? "R.Wieser" <address@is.invalid> - 2025-04-03 13:10 +0200
Re: what is the fastest command line copy? Newyana2 <newyana@invalid.nospam> - 2025-04-02 07:57 -0400
Re: what is the fastest command line copy? "R.Wieser" <address@is.invalid> - 2025-04-02 16:19 +0200
Re: what is the fastest command line copy? Newyana2 <newyana@invalid.nospam> - 2025-04-02 11:04 -0400
Re: what is the fastest command line copy? Paul <nospam@needed.invalid> - 2025-04-02 12:04 -0400
Re: what is the fastest command line copy? "R.Wieser" <address@is.invalid> - 2025-04-02 18:06 +0200
Re: what is the fastest command line copy? Frank Slootweg <this@ddress.is.invalid> - 2025-04-02 12:41 +0000
Re: what is the fastest command line copy? Paul <nospam@needed.invalid> - 2025-04-02 12:15 -0400
Re: what is the fastest command line copy? Frank Slootweg <this@ddress.is.invalid> - 2025-04-02 17:36 +0000
Re: what is the fastest command line copy? Stan Brown <the_stan_brown@fastmail.fm> - 2025-04-02 10:50 -0700
Re: what is the fastest command line copy? Steve Hayes <hayesstw@telkomsa.net> - 2025-04-03 05:24 +0200
Re: what is the fastest command line copy? Democrat <Democrat@invalid.invalid> - 2025-04-03 06:00 +0000
Re: what is the fastest command line copy? "R.Wieser" <address@is.invalid> - 2025-04-03 08:39 +0200
Re: what is the fastest command line copy? Steve Hayes <hayesstw@telkomsa.net> - 2025-04-03 15:55 +0200
Re: what is the fastest command line copy? Frank Slootweg <this@ddress.is.invalid> - 2025-04-03 15:06 +0000
Re: what is the fastest command line copy? Steve Hayes <hayesstw@telkomsa.net> - 2025-04-04 13:55 +0200
Re: what is the fastest command line copy? Frank Slootweg <this@ddress.is.invalid> - 2025-04-04 12:11 +0000
Re: what is the fastest command line copy? Don_from_AZ <djatechNOSPAM@comcast.net.invalid> - 2025-04-04 10:32 -0700
Re: what is the fastest command line copy? Steve Hayes <hayesstw@telkomsa.net> - 2025-04-05 05:20 +0200
Re: what is the fastest command line copy? T <T@invalid.invalid> - 2025-04-05 00:44 -0700
Re: what is the fastest command line copy? Daniel70 <daniel47@eternal-september.org> - 2025-04-06 20:20 +1000
Re: what is the fastest command line copy? "Kerr-Mudd, John" <admin@127.0.0.1> - 2025-04-06 21:15 +0100
Re: what is the fastest command line copy? Newyana2 <newyana@invalid.nospam> - 2025-04-04 08:49 -0400
Re: what is the fastest command line copy? Steve Hayes <hayesstw@telkomsa.net> - 2025-04-05 05:29 +0200
Re: what is the fastest command line copy? Newyana2 <newyana@invalid.nospam> - 2025-04-05 08:26 -0400
Re: what is the fastest command line copy? Paul <nospam@needed.invalid> - 2025-04-05 00:37 -0400
Re: what is the fastest command line copy? Newyana2 <newyana@invalid.nospam> - 2025-04-05 08:18 -0400
Re: what is the fastest command line copy? Char Jackson <none@none.invalid> - 2025-04-03 11:00 -0500
Re: what is the fastest command line copy? Newyana2 <newyana@invalid.nospam> - 2025-04-02 07:53 -0400
Re: what is the fastest command line copy? "R.Wieser" <address@is.invalid> - 2025-04-02 16:26 +0200
Re: what is the fastest command line copy? Newyana2 <newyana@invalid.nospam> - 2025-04-02 11:03 -0400
Re: what is the fastest command line copy? "R.Wieser" <address@is.invalid> - 2025-04-02 18:04 +0200
Re: what is the fastest command line copy? Paul <nospam@needed.invalid> - 2025-04-02 12:36 -0400
Re: what is the fastest command line copy? Newyana2 <newyana@invalid.nospam> - 2025-04-02 13:07 -0400
Re: what is the fastest command line copy? Paul <nospam@needed.invalid> - 2025-04-03 04:14 -0400
Re: what is the fastest command line copy? Newyana2 <newyana@invalid.nospam> - 2025-04-03 08:40 -0400
Re: what is the fastest command line copy? Stan Brown <the_stan_brown@fastmail.fm> - 2025-04-02 10:43 -0700
Re: what is the fastest command line copy? Char Jackson <none@none.invalid> - 2025-04-02 18:59 -0500
Re: what is the fastest command line copy? Stan Brown <the_stan_brown@fastmail.fm> - 2025-04-02 11:11 -0700
Re: what is the fastest command line copy? knuttle <keith_nuttle@yahoo.com> - 2025-03-31 10:59 -0400
Re: what is the fastest command line copy? "R.Wieser" <address@is.invalid> - 2025-03-31 17:26 +0200
Re: what is the fastest command line copy? Newyana2 <newyana@invalid.nospam> - 2025-03-31 13:05 -0400
Re: what is the fastest command line copy? "R.Wieser" <address@is.invalid> - 2025-03-31 20:18 +0200
Re: what is the fastest command line copy? Newyana2 <newyana@invalid.nospam> - 2025-03-31 14:43 -0400
Re: what is the fastest command line copy? Stan Brown <the_stan_brown@fastmail.fm> - 2025-03-31 13:40 -0700
Re: what is the fastest command line copy? T <T@invalid.invalid> - 2025-03-30 23:03 -0700
Re: what is the fastest command line copy? T <T@invalid.invalid> - 2025-03-30 23:43 -0700
Re: what is the fastest command line copy? T <T@invalid.invalid> - 2025-04-01 02:01 -0700
Page 4 of 4 — ← Prev page 1 2 3 [4]
| From | Newyana2 <newyana@invalid.nospam> |
|---|---|
| Date | 2025-04-02 07:53 -0400 |
| Message-ID | <vsj8dm$1ot1m$1@dont-email.me> |
| In reply to | #18175 |
On 4/2/2025 2:50 AM, Steve Hayes wrote:
>> The whole point of scripting for me is
>> so that I only have to do something once. Next time I only have
>> to double-click or drag-drop.
>
> I'm not sure what you're saying here.
>
> I have four batch files:
>
> dsk2flsh.bat
> flsh2lap.bat
> lap2flsh.bat
> flsh2dsk.bat
>
> I only have to remember the exact syntax when I make the batch files,
> and after that I I have to remember is the name of the batch file.
>
Yes. That's one way of operating. As you said, that's
technically a way of scripting, inasmuch as it's interpreted
text. I was comparing scripting in the sense of WSH to
typing commands in a console window. As I said at the start,
life is too short for commandline. There's a fetish aspect to
typing into console windows that oldtimers like and young
people regard as a hazing process. It's much worse on Linux.
And it's not unusual that I get stuck using that method.
Every time I want to update my Raspberry Pi I have to find
that little piece of paper I saved that records the requisite
incantations. That's simply a case of programmers not finishing
the job. After 30 years of GUI we shouldn't ever HAVE TO open
a console window.
Much of the reason we do is not even programmer
laziness. It's more oldtimer stubbornness. Awhile back I was
trying out Xubuntu and couldn't adjust the clock. Odd. I finally
found a discussion online where the man who coded the clock said
that he specifically didn't add GUI settings because he finds
console window easier. But it's a GUI system! He's like a kid in
a self-driving car who likes to have a clutch pedal just so that he
can feel like he's a cowboy. And he wants everyone to know
that he's a cowboy, who's so tough that he's even played video
games of wrestling a grizzly bear. So he's not going to let anyone
else adjust the clock via GUI, either.
I have a file that I keep on hand to remind me of various DISM
commands I need. Could I put those in a PS script? Maybe. But I
usually just need one. In fact I have a VBS script to clean TEMP
files, then I pop up a messagebox at the end that says,
"Also clean up winsxs with this command:
Dism.exe /online /Cleanup-Image /StartComponentCleanup /ResetBase"
That way I don't have to go looking up the command. I can just copy
and paste from the messagebox window. But why
isn't there a "Cleanup winsxs" button in System -> Advanced Options
-> Advanced -> Advanced -> Advanced -> Advanced?
If you're only using pre-written BAT files then that's different.
So, then, what's the difference between that and WSH?
The difference would be that
BAT files are a primitive approach that WSH was designed
to replace... 30 years ago. Very limited GUI options. Very limited
options for multiple contexts and concurrent operations. No
classes, subroutines, etc. No way to exploit the vast COM
libraries on Windows. Mostly just one-liner calls to
external applets that can do something for you. Your 4 BAT
files only provide options for 4 exact copy operations from A
to B, B to A, A to C, C to A. In other words, it's a 30-year-old
paradigm intended for console screens. My drag-drop script
defines the files to move through simple drag-drop. The options
are unlimited. GUI. Post-1995.
DOS/BAT is basically one-liner calls that ignore
the vast programming options that Microsoft developed since
1995. It's designed to mimic the DOS command screen that
oldtimers know from pre-GUI days.
DOS/BAT, and now PS, work well for people who started
with DOS and don't need anything else. As I said, scripting
is not for everyone. I was just just pointing out, for anyone
who's curious, that there are options to use more customized
approaches that are not just complicated incantation one-liners
strung together.
[toc] | [prev] | [next] | [standalone]
| From | "R.Wieser" <address@is.invalid> |
|---|---|
| Date | 2025-04-02 16:26 +0200 |
| Message-ID | <vsjhfo$222l7$3@dont-email.me> |
| In reply to | #18183 |
Newyana2, > As I said at the start, life is too short for commandline. How do you keep tabs on the progress of your scripts ? Personally I like seeing a long-running script telling me what its currently doing. And the easiest way is to run the (VB)Script in a console so that you can see what its outputting - without having to press the "OK" button on everything it outputs. Though that doesn't mean you can't start them by double-clicking or dropping files/folders onto them. Regards, Rudy Wieser
[toc] | [prev] | [next] | [standalone]
| From | Newyana2 <newyana@invalid.nospam> |
|---|---|
| Date | 2025-04-02 11:03 -0400 |
| Message-ID | <vsjjhb$2446b$1@dont-email.me> |
| In reply to | #18191 |
On 4/2/2025 10:26 AM, R.Wieser wrote:
> Newyana2,
>
>> As I said at the start, life is too short for commandline.
>
> How do you keep tabs on the progress of your scripts ?
>
> Personally I like seeing a long-running script telling me what its currently
> doing. And the easiest way is to run the (VB)Script in a console so that
> you can see what its outputting - without having to press the "OK" button on
> everything it outputs.
>
> Though that doesn't mean you can't start them by double-clicking or dropping
> files/folders onto them.
>
I've never used the console output. Generally I just
use error trapping and show a msgbox at the end: "Done."
For instance, if a script expects a dropped file then if there
is no drop then I'll show an inputbox or a message.
For scripts that I'm going to use more than once I try
to make them robust in that way. I check whether files
exist, I confirm math operations... then at the end I add
On Error Resume Next. So I don't really need to monitor
anything. That's done when writing the script. Much of the
point is to be able to just double-click or drop and have
the details taken care of. It shouldn't need console output.
For more complicated things I'll do as Paul described, using
numbered errors. But that's mostly in compiled software,
where I'm using 3rd-party libraries that might return errors,
which I might want to be able to troubleshoot. But even then,
there shouldn't be errors or weaknesses in my own code. If
I put up an inputbox for a file path, that path should exist.
If I put up an inputbox for a number, that should pass
IsNumeric.
If I want a report then I put that in the script. for instance,
my file copy script generates a text file listing what was
copied.
What kinds of things do you do that need console reporting
mid-script?
[toc] | [prev] | [next] | [standalone]
| From | "R.Wieser" <address@is.invalid> |
|---|---|
| Date | 2025-04-02 18:04 +0200 |
| Message-ID | <vsjno9$28jln$1@dont-email.me> |
| In reply to | #18192 |
Newyana2, > Generally I just use error trapping and show a msgbox at the end: "Done." The "error trapping" goes without saying. As for the latter ? I've got short-running scripts I do not even bother to let them tell they are finished. But when its a longer-running script (or one making a lot of changes) than I have the need to see it progressing. Yes, my earlier long-running scripts finished like yours, with a msgbox. But have you never noticed that time slows to a crawl when you are waiting for something to happen but have no idea how long it will take ? I rather see paint dry. The easiest "progres indicator" is to output to a console window. > If I want a report then I put that in the script. for instance, > my file copy script generates a text file listing what was > copied. Same here. What was updated, was new, or could not be copied for whatever reason. Regards, Rudy Wieser
[toc] | [prev] | [next] | [standalone]
| From | Paul <nospam@needed.invalid> |
|---|---|
| Date | 2025-04-02 12:36 -0400 |
| Message-ID | <vsjp1i$2a1kj$1@dont-email.me> |
| In reply to | #18192 |
On Wed, 4/2/2025 11:03 AM, Newyana2 wrote: > > What kinds of things do you do that need console reporting > mid-script? > For long running scripts, you could use a bit of progress indication. What percent done. In the old days, this was the entering of dots on the screen. And my favorites were always the programming efforts where the "dots went off the side of the screen". Such attention to detail :-) The people doing that, didn't know the terminal in that case, didn't have autowrap. (Yes, there were actually terminal emulators *that* crude.) In my Robocopy command, you can see I like to use the output as a form of progress indication, as well as making a permanent log. robocopy Y:\ F:\ /mir /COPYALL /dcopy:t /XJ /r:3 /w:2 /zb /np /tee /v /log:robocopy_y_to_f.log /tee # Log to screen, log to file /v # Verbose /log:robocopy_y_to_f.log # Each run gets a logfile (for unique src:dest pairs) You don't actually look at that. The idea is, you open a Terminal, paste the command, then... watch that the run has started OK. Iconify. Open the Terminal after ten minutes, inspect and see it's still on target. Iconify. You can use Task Manager or the disk LED, to identify the command is thoroughly done. Paul
[toc] | [prev] | [next] | [standalone]
| From | Newyana2 <newyana@invalid.nospam> |
|---|---|
| Date | 2025-04-02 13:07 -0400 |
| Message-ID | <vsjqr5$2bp20$1@dont-email.me> |
| In reply to | #18200 |
On 4/2/2025 12:36 PM, Paul wrote:
> On Wed, 4/2/2025 11:03 AM, Newyana2 wrote:
>
>>
>> What kinds of things do you do that need console reporting
>> mid-script?
>>
>
> For long running scripts, you could use a bit of progress indication.
> What percent done.
>
> In the old days, this was the entering of dots on the screen.
> And my favorites were always the programming efforts where
> the "dots went off the side of the screen". Such attention
> to detail :-) The people doing that, didn't know the terminal
> in that case, didn't have autowrap. (Yes, there were actually
> terminal emulators *that* crude.)
>
> In my Robocopy command, you can see I like to use the output
> as a form of progress indication, as well as making a
> permanent log.
>
> robocopy Y:\ F:\ /mir /COPYALL /dcopy:t /XJ /r:3 /w:2 /zb /np /tee /v /log:robocopy_y_to_f.log
>
> /tee # Log to screen, log to file
> /v # Verbose
> /log:robocopy_y_to_f.log # Each run gets a logfile (for unique src:dest pairs)
>
> You don't actually look at that. The idea is, you open a Terminal, paste
> the command, then... watch that the run has started OK. Iconify. Open
> the Terminal after ten minutes, inspect and see it's still on target.
> Iconify. You can use Task Manager or the disk LED, to identify the
> command is thoroughly done.
>
> Paul
>
I haven't really run into such situations. On rare occasions I
might have a script where I'm surprised at the slow speed. But
I just optimize as much as possible and live with it. Usually scripts
like that are one-time operations.
I have found some surprising details about speed with VBS.
For example, with a lot of text it's much faster to put each small
string into an array and then run a Join than to keep concatenating
little strings past the point of petty cash memory reserveed by WSH.
Another surprising difference is that if a lot of string operations
are to be done then it's good to convert it to UCase or LCase
first.
Once I've done those kinds of optimizations, and I know the
script works, I'm happy to just let it do its work. I don't need
to see a progress bar. I could, theoretically, set up a GUI progress
bar, but even if I cared, getting accurate percentage of progress
is usually not possible.
[toc] | [prev] | [next] | [standalone]
| From | Paul <nospam@needed.invalid> |
|---|---|
| Date | 2025-04-03 04:14 -0400 |
| Message-ID | <vslg1h$652v$1@dont-email.me> |
| In reply to | #18202 |
On Wed, 4/2/2025 1:07 PM, Newyana2 wrote:
> I haven't really run into such situations. On rare occasions I
> might have a script where I'm surprised at the slow speed. But
> I just optimize as much as possible and live with it. Usually scripts
> like that are one-time operations.
>
> I have found some surprising details about speed with VBS.
> For example, with a lot of text it's much faster to put each small
> string into an array and then run a Join than to keep concatenating
> little strings past the point of petty cash memory reserveed by WSH.
>
> Another surprising difference is that if a lot of string operations
> are to be done then it's good to convert it to UCase or LCase
> first.
>
> Once I've done those kinds of optimizations, and I know the
> script works, I'm happy to just let it do its work. I don't need
> to see a progress bar. I could, theoretically, set up a GUI progress
> bar, but even if I cared, getting accurate percentage of progress
> is usually not possible.
The OS is chock full of examples of "energy waste working up data
for progress indicators" and "indicators that were nuts".
I like the CHKDSK one that says "15 minute remaining" and one
second later, the command run is finished. Now, that's a progress
indicator.
The progress shown in Macrium is not bad, with the exception
that some operations have text telling you the transfer rate
and others, do not.
You can get rough indications of progress, using Task Manager
and adding "I/O Read Bytes" and "I/O Write Bytes" columns. If you
know a command of yours will be doing 70GB of transfers, you
can check Task Manager and "see how much work it has done",
to get some idea how much is left to do.
The performance counters on Windows, don't work for everything,
so some attempts to add instrumentation to your screen, just
aren't going to work. You can set up a perfmon.msc screen
to monitor rates. One of the tricks there, is setting the Y axis
scaling, so the results fit on the screen properly.
For disk read/write, I set the graph axis to "800000" which
is apparently 8GB/sec, so that my 2GB/sec and 3GB/sec activities
can be seen. This is my little paulcopy64.exe program, copying
a file (because it's a dumb little program). It uses fread and fwrite.
The storage device can do 6.5GB/sec, so the result indicates
my program needs work.
[Picture]
https://i.postimg.cc/wxncp9r5/perfmon-msc.gif
Paul
[toc] | [prev] | [next] | [standalone]
| From | Newyana2 <newyana@invalid.nospam> |
|---|---|
| Date | 2025-04-03 08:40 -0400 |
| Message-ID | <vslvhn$m4kn$1@dont-email.me> |
| In reply to | #18219 |
On 4/3/2025 4:14 AM, Paul wrote: > The OS is chock full of examples of "energy waste working up data > for progress indicators" and "indicators that were nuts". > > I like the CHKDSK one that says "15 minute remaining" and one > second later, the command run is finished. Now, that's a progress > indicator. > Copy in general shows wacky progress. It seems to be based on something like file size. Since it changes depending on the file I'd guess that it's not a case of adding up ythe total bytes to be copied and dividing by 100. On the other hand, I'm rarely doing anything that I have to wait for with script. For instance, I regularly process my server logs to replace IP address with hostname and location. I processed free records from MaxMind, adding location data into an MSI file. (Which is actually a database. I love MSIs for this kind of thing. They're very fast and can handle vast data.) So my script will take each IP make a hostname call through my own component, do a lookup in the location database, then update the array item in the array of server log lines. On XP it took several minutes. On 10 it's much faster. (Maybe faster network operations?) But it really doesn't matter. I'm not waiting for it. I'm doing other things while it runs.
[toc] | [prev] | [next] | [standalone]
| From | Stan Brown <the_stan_brown@fastmail.fm> |
|---|---|
| Date | 2025-04-02 10:43 -0700 |
| Message-ID | <MPG.4257170d2253240a9903d9@news.individual.net> |
| In reply to | #18175 |
On Wed, 02 Apr 2025 08:50:34 +0200, Steve Hayes wrote: > I have four batch files: > > dsk2flsh.bat > flsh2lap.bat > lap2flsh.bat > flsh2dsk.bat > > I only have to remember the exact syntax when I make the batch files, > and after that I I have to remember is the name of the batch file. You left out one very big thing to remember: whenever you change which files are synched by one of those .bat files, you must remember to change the other three. Having to do redundant maintenance is a fruitful source of bugs. I know, it's your files and you will surely remember to do the extra work. It's a pain to do it four times, but probably not a major pain. Being a fanatic about avoiding duplicate maintenance, I went a different way. I have one file (fdrv.btm) for synching all files, and a second (usb.btm) for synching just the small subset of files that I work on often. Each of those requires an argument /frompc or /topc to determine the direction of the copy, and accepts additional options like /L. A separate file (robowrap.btm) is called by usb.btm or fdrv.btm. It uses /frompc or /topc and other arguments passed by the two main files, adds always-used arguments like /XO and the log file, calls robocopy, and checks the return status. -- Stan Brown, Tehachapi, California, USA https://BrownMath.com/ Shikata ga nai...
[toc] | [prev] | [next] | [standalone]
| From | Char Jackson <none@none.invalid> |
|---|---|
| Date | 2025-04-02 18:59 -0500 |
| Message-ID | <gajruj569ltvsntodlmhppslcn3rmo24am@4ax.com> |
| In reply to | #18204 |
On Wed, 2 Apr 2025 10:43:15 -0700, Stan Brown <the_stan_brown@fastmail.fm> wrote: >On Wed, 02 Apr 2025 08:50:34 +0200, Steve Hayes wrote: >> I have four batch files: >> >> dsk2flsh.bat >> flsh2lap.bat >> lap2flsh.bat >> flsh2dsk.bat >> >> I only have to remember the exact syntax when I make the batch files, >> and after that I I have to remember is the name of the batch file. > >You left out one very big thing to remember: whenever you change >which files are synched by one of those .bat files, you must remember >to change the other three. Having to do redundant maintenance is a >fruitful source of bugs. Just spit balling, but what if the 4 .bat files read their variables from a shared .ini file? Edit just the .ini and all of the .bat files pick up the change. Or combine the 4 .bat files into one, with a shared header section to facilitate single-place editing, plus a command line switch to trigger execution of the proper section. I just noticed that I repeatedly focused on variables, for some reason. >I know, it's your files and you will surely remember to do the extra >work. It's a pain to do it four times, but probably not a major pain. > >Being a fanatic about avoiding duplicate maintenance, I went a >different way. I have one file (fdrv.btm) for synching all files, and >a second (usb.btm) for synching just the small subset of files that I >work on often. Each of those requires an argument /frompc or /topc to >determine the direction of the copy, and accepts additional options >like /L. A separate file (robowrap.btm) is called by usb.btm or >fdrv.btm. It uses /frompc or /topc and other arguments passed by the >two main files, adds always-used arguments like /XO and the log file, >calls robocopy, and checks the return status.
[toc] | [prev] | [next] | [standalone]
| From | Stan Brown <the_stan_brown@fastmail.fm> |
|---|---|
| Date | 2025-04-02 11:11 -0700 |
| Message-ID | <MPG.42571da0590a5ba39903db@news.individual.net> |
| In reply to | #18175 |
On Wed, 02 Apr 2025 08:50:34 +0200, Steve Hayes wrote:
> I have four batch files:
>
> dsk2flsh.bat
> flsh2lap.bat
> lap2flsh.bat
> flsh2dsk.bat
>
> I only have to remember the exact syntax when I make the batch files,
> and after that I I have to remember is the name of the batch file.
When I write a batch file with complicated command-line syntax, I
always use this pattern:
if "%1" != "/?" goto 000_Start
:: Display syntax with ECHO commands
exit
:000_Start
:: the actual program
That's TCCLE syntax, but you get the idea.
It can be a nuisance to update the help message when I update the
program arguments(*) but it's also a useful opportunity to look back
and see if there's a better way to do the job than I knew when I
wrote the file.
(*) See my rant about duplicate maintenance in
Message-ID: <MPG.4257170d2253240a9903d9@news.individual.net>
--
Stan Brown, Tehachapi, California, USA https://BrownMath.com/
Shikata ga nai...
[toc] | [prev] | [next] | [standalone]
| From | knuttle <keith_nuttle@yahoo.com> |
|---|---|
| Date | 2025-03-31 10:59 -0400 |
| Message-ID | <vseakb$havq$1@dont-email.me> |
| In reply to | #18105 |
On 03/31/2025 9:47 AM, R.Wieser wrote: > Newyana2, > >> * Windows doesn't provide an option to only copy >> over newer files. > > I don't know if Win10 still has XCopy, but it seems that it can do that : > > /D:m-d-y Copies files changed on or after the specified date. > If no date is given, copies only those files whose > source time is newer than the destination time. > >> * Windows 10 seems to be faulty, typically not copying a folder that >> already exists. I have to delete the old folder by hand or the >> copy/replace doesn't work. > > an ownership problem ? > > Regards, > Rudy Wieser > > I use third party software SyncBackFree: https://www.2brightsparks.com/downloads.html It is free for use, and gives you a lot of options to back up you computer. I have used the free version for over a decade to sync my laptop and desktop. I have also the backup funtion and mirror function on other computers. It is easy to set up what you want done with specific files and folders. It is easy to run to do what you have set up in the program.
[toc] | [prev] | [next] | [standalone]
| From | "R.Wieser" <address@is.invalid> |
|---|---|
| Date | 2025-03-31 17:26 +0200 |
| Message-ID | <vsecjb$kfh4$1@dont-email.me> |
| In reply to | #18107 |
Knuttle, > I use third party software SyncBackFree: Don't tell me. I wrote my own file-backup program. :-) (Why ? Because I wanted to know if I could) Regards, Rudy Wieser
[toc] | [prev] | [next] | [standalone]
| From | Newyana2 <newyana@invalid.nospam> |
|---|---|
| Date | 2025-03-31 13:05 -0400 |
| Message-ID | <vsehu8$pqls$1@dont-email.me> |
| In reply to | #18109 |
On 3/31/2025 11:26 AM, R.Wieser wrote:
> Knuttle,
>
>> I use third party software SyncBackFree:
>
> Don't tell me. I wrote my own file-backup program. :-) (Why ? Because I
> wanted to know if I could)
>
I've never really done much of this. You're backing up daily?
I just keep redundant copies on matching disks, store all important
things on a 3 GB partition, then periodically write desktop, appdata
and that partition's content to a DVD. So much is longterm data.
Photos, tech info, reference materials, videos -- none of that
changes, so I just put it on USB sticks once in a while. Along with
disk images, I periodically put copies of all that in a safe deposit
box.
[toc] | [prev] | [next] | [standalone]
| From | "R.Wieser" <address@is.invalid> |
|---|---|
| Date | 2025-03-31 20:18 +0200 |
| Message-ID | <vsemdg$ujvc$1@dont-email.me> |
| In reply to | #18112 |
Newyana2, > I've never really done much of this. You're backing up daily? No, its a monthly thing on that an USB drive. Though I've got an USB stick on which I backup my "high change" (source) files a bit more frequently (using vbscript, checking for newer files :-) ). > So much is longterm data. Photos, tech info, reference materials, For me its mostly the latter two. Hence the monthly. > Along with disk images, I periodically put copies of all that in a safe > deposit box. Following the "a backup on the same 'puter isn't a backup. A backup stored in the same building isn't a backup either" saying I see. :-) Regards, Rudy Wieser
[toc] | [prev] | [next] | [standalone]
| From | Newyana2 <newyana@invalid.nospam> |
|---|---|
| Date | 2025-03-31 14:43 -0400 |
| Message-ID | <vsenms$10345$1@dont-email.me> |
| In reply to | #18118 |
On 3/31/2025 2:18 PM, R.Wieser wrote:
> Newyana2,
>
>> I've never really done much of this. You're backing up daily?
>
> No, its a monthly thing on that an USB drive. Though I've got an USB stick
> on which I backup my "high change" (source) files a bit more frequently
> (using vbscript, checking for newer files :-) ).
>
>> So much is longterm data. Photos, tech info, reference materials,
>
> For me its mostly the latter two. Hence the monthly.
>
>> Along with disk images, I periodically put copies of all that in a safe
>> deposit box.
>
> Following the "a backup on the same 'puter isn't a backup. A backup stored
> in the same building isn't a backup either" saying I see. :-)
>
Covering different bases. If I lose it tomorrow, am I prepared?
Pretty much. Though total loss would be a big hassle. Like you I
back up frequently to a stick if I'm working on something. But I'm
very organized, so I don't really check by dates. I deal with
locations.
[toc] | [prev] | [next] | [standalone]
| From | Stan Brown <the_stan_brown@fastmail.fm> |
|---|---|
| Date | 2025-03-31 13:40 -0700 |
| Message-ID | <MPG.42549d8dfcca34ed9903d4@news.individual.net> |
| In reply to | #18086 |
On Mon, 31 Mar 2025 04:43:39 +0200, Steve Hayes wrote:
> On Mon, 31 Mar 2025 02:12:05 +0100, Dual Boot Windows
> <invalid@invalid.invalid> wrote:
>
> > [quoted text muted]
> >users prefer GUI version.
> >
> ><https://fastcopy.jp/>
> >
>
> Does xcopy/xxcopy still work?
>
> I want something that works with batch files to automate transfer of
> data files from desktop to laptop & vice versa via USB flash drive.
That's what I use Robocopy for, several times a day, in a batch file
I call ... usb. (Well, usb.btm, if you want to get technical, since
I'm using TCCLE as my shell.)
Xcooy is part of the OS, as you could have found by typing
xcopy /?
on the command line. I've never used it myself.
--
Stan Brown, Tehachapi, California, USA https://BrownMath.com/
Shikata ga nai...
[toc] | [prev] | [next] | [standalone]
| From | T <T@invalid.invalid> |
|---|---|
| Date | 2025-03-30 23:03 -0700 |
| Message-ID | <vsdb7b$3g059$2@dont-email.me> |
| In reply to | #18085 |
On 3/30/25 6:12 PM, Dual Boot Windows wrote: > On 30/03/2025 00:03, T wrote: >> Hi All, >> >> It use to be robo copy for a mass copy of a >> directory. Does that still exist? Or is >> there something better? >> >> Many thanks, >> -T >> > > > You can use FastCopy GUI program. It has a cmd line built in but Windows > users prefer GUI version. > > <https://fastcopy.jp/> Thank you! Two follow up questions. 1) Do you know how it handles files with file locks on them? Will it use the "Shadow" (VSS)? 2) If it find a file with an "issue", will it skip and complain or will it halt?
[toc] | [prev] | [next] | [standalone]
| From | T <T@invalid.invalid> |
|---|---|
| Date | 2025-03-30 23:43 -0700 |
| Message-ID | <vsddi9$3g059$3@dont-email.me> |
| In reply to | #18085 |
On 3/30/25 6:12 PM, Dual Boot Windows wrote: > It has a cmd line built in but Windows > users prefer GUI version. > > <https://fastcopy.jp/> https://fastcopy.jp/help/fastcopy_eng.htm#cmdline
[toc] | [prev] | [next] | [standalone]
| From | T <T@invalid.invalid> |
|---|---|
| Date | 2025-04-01 02:01 -0700 |
| Message-ID | <vsga16$ph1f$5@dont-email.me> |
| In reply to | #18085 |
On 3/30/25 6:12 PM, Dual Boot Windows wrote: > On 30/03/2025 00:03, T wrote: >> Hi All, >> >> It use to be robo copy for a mass copy of a >> directory. Does that still exist? Or is >> there something better? >> >> Many thanks, >> -T >> > > > You can use FastCopy GUI program. It has a cmd line built in but Windows > users prefer GUI version. > > <https://fastcopy.jp/> I bought a perpetual license. I took me a bit to figure out the command line, but afterwards, it works awesome.
[toc] | [prev] | [standalone]
Page 4 of 4 — ← Prev page 1 2 3 [4]
Back to top | Article view | alt.comp.os.windows-11
csiph-web