QLCommander v 2.2.7- For Testers!

Anything QL Software or Programming Related.
User avatar
Andrew
QL Wafer Drive
Posts: 1031
Joined: Tue Jul 17, 2018 9:10 pm

Re: QLCommander v 2.2.7- For Testers!

Post by Andrew »

javier2112 wrote: Thu Mar 20, 2025 10:59 am Andrei, I've got a suggestion for future releases: now, when you rename a directory, the used destination name is always relative to the current directory, but if the new path starts with a device name, I think QLC could ask user to rename to an absolute path or not, or at least, rename to an absolute path without asking.

What do you think?
I thought of that, but I decided against it because it would have complicated the code too much.
You can achieve this in the current version by using a MOVE + Rename or by a Copy + Rename

In QDOS you can rename a file but you cannot rename a directory. Also rename can change the name of a file, but not the drive.
So what I do in the program is this:

RENAME
  • re-create all directory structure
  • rename all files in the tree (because I know for sure that we are on the same drive, and rename works)
  • delete the old directory structure
MOVE
1. if we move on the same drive: I perform a RENAME (as above)
2. if we move on a different drive then
  • re-create all directory structure on new drive and path
  • copy all files in the tree
  • delete the old directory structure including the files
It would be easier to modify MOVE command and ask the user for a new full path, but the whole process would be slower as this would add a lot of path checks in the program and more user interaction. Also it would be prone to more user errors, as not all users fully understand the peculiarities of the Level 2 directories.


javier2112
ROM Dongle
Posts: 40
Joined: Thu Jan 27, 2022 6:02 pm

Re: QLCommander v 2.2.7- For Testers!

Post by javier2112 »

Andrew wrote: Thu Mar 20, 2025 11:53 am (...)
It would be easier to modify MOVE command and ask the user for a new full path, but the whole process would be slower as this would add a lot of path checks in the program and more user interaction. Also it would be prone to more user errors, as not all users fully understand the peculiarities of the Level 2 directories.
I understand, but as a particular case, if destination drive is the same than source, the checks'd be simpler, wouldn't?

I load in my boot file an extension called DireXt that do the thing as I expected in this particular case.


User avatar
Andrew
QL Wafer Drive
Posts: 1031
Joined: Tue Jul 17, 2018 9:10 pm

Re: QLCommander v 2.2.7- For Testers!

Post by Andrew »

javier2112 wrote: Thu Mar 20, 2025 12:34 pm I load in my boot file an extension called DireXt that do the thing as I expected in this particular case.
Yes, I know DIrExt - great toolkit by Alain Haoui
But DirExt doesn't have all the overhead with the interface that QLCommander has. If a user sets some wrong/illegal path then dirext will just throw an error and doesn't have to bother with trapping the error and not letting it propagate in the interface and crashing the whole program ;)

There are other corner cases that I considered, also.
Like move directory X1 from win1_aaa_bbb_x1 to win2_ccc_dddd_x2

Now let's presume that directories ccc and dddd do not exist on Win2
So what do we have to do?
option 1:
- Create a directory named ccc_dddd_ on win2
- move the contents of x1 from win1_aaa_bbb_x1 to win2_ccc_dddd_x2

option 2:
- Create a directory named ccc on win2
- create subdirectory named dddd in win2_ccc_
- move the contents of x1 from win1_aaa_bbb_x1 to win2_ccc_dddd_x2

option 3:
- Create a directory named ccc_dddd_x2_x1_ on win2
- move the contents of x1 from win1_aaa_bbb_x1 to win2_ccc_dddd_x2_x1

option 4
- Create a directory named ccc on win2
- create subdirectory named dddd in win2_ccc_
- create subdirectory named x2 in win2_ccc_ddd_
- move the contents of x1 from win1_aaa_bbb_x1 to win2_ccc_dddd_x2_x1

and so on. All option are valid in QDOS. And the same options apply also for moving on the same drive, from win1_aaa_bbb_x1 to win1_ccc_dddd_x2
I feel that whatever decision QLCommander makes there will always be some unhappy users because the result is not what they thought it will be.

So I prefer to use KISS (Keep it simple, stupid!) If a user wants to move and rename than he can do a MOVE + RENAME or a COPY+RENAME.
It's faster and it's clearer for the user what the result will be.


EmmBee
Trump Card
Posts: 245
Joined: Fri Jan 13, 2012 5:29 pm
Location: Kent

Re: QLCommander v 2.2.7- For Testers!

Post by EmmBee »

Andrew wrote: Tue Mar 18, 2025 7:26 pm
Please download and test the new version
I notice that the config program is not included in this latest release.


User avatar
Andrew
QL Wafer Drive
Posts: 1031
Joined: Tue Jul 17, 2018 9:10 pm

Re: QLCommander v 2.2.7- For Testers!

Post by Andrew »

EmmBee wrote: Fri Mar 21, 2025 9:50 am I notice that the config program is not included in this latest release.
Sorry about that.
Anyways, I deleted the test version from the Forum. Please download the final version https://www.theqlforum.com/viewtopic.php?p=63754#p63754
Last edited by Andrew on Fri Mar 21, 2025 10:16 am, edited 1 time in total.


EmmBee
Trump Card
Posts: 245
Joined: Fri Jan 13, 2012 5:29 pm
Location: Kent

Re: QLCommander v 2.2.7- For Testers!

Post by EmmBee »

Andrew wrote: Fri Mar 21, 2025 9:56 am
EmmBee wrote: Fri Mar 21, 2025 9:50 am I notice that the config program is not included in this latest release.
Soryy about that.
Anyways, I deleted the test version from the Forum. Please download the final version https://www.theqlforum.com/viewtopic.php?p=63754#p63754
The exe file seems to have the wrong Turbo Taskname - it says M2 - not M5


User avatar
Andrew
QL Wafer Drive
Posts: 1031
Joined: Tue Jul 17, 2018 9:10 pm

Re: QLCommander v 2.2.7- For Testers!

Post by Andrew »

EmmBee wrote: Fri Mar 21, 2025 10:03 am The exe file seems to have the wrong Turbo Taskname - it says M2 - not M5
I downloaded it and rechecked it - it says QLC227M7


javier2112
ROM Dongle
Posts: 40
Joined: Thu Jan 27, 2022 6:02 pm

Re: QLCommander v 2.2.7- For Testers!

Post by javier2112 »

Andrew wrote: Thu Mar 20, 2025 1:11 pm There are other corner cases that I considered, also.
Like move directory X1 from win1_aaa_bbb_x1 to win2_ccc_dddd_x2

Now let's presume that directories ccc and dddd do not exist on Win2
So what do we have to do?
option 1:
- Create a directory named ccc_dddd_ on win2
- move the contents of x1 from win1_aaa_bbb_x1 to win2_ccc_dddd_x2

(...)

l that whatever decision QLCommander makes there will always be some unhappy users because the result is not what they thought it will be.

So I prefer to use KISS (Keep it simple, stupid!) If a user wants to move and rename than he can do a MOVE + RENAME or a COPY+RENAME.
It's faster and it's clearer for the user what the result will be.
I agree with you, I see the problem turns very complicated.


User avatar
desin
Brittle Membrane
Posts: 117
Joined: Mon May 10, 2021 10:33 am

Re: QLCommander v 2.2.7- For Testers!

Post by desin »

Looks way better
but
what about _bin files ?
set ramx_ as temp directory ?

Greetings from Switzerland
Markus


User avatar
Andrew
QL Wafer Drive
Posts: 1031
Joined: Tue Jul 17, 2018 9:10 pm

Re: QLCommander v 2.2.7- For Testers!

Post by Andrew »

desin wrote: Fri Mar 21, 2025 7:39 pm but
what about _bin files ?
What about _bin files??
desin wrote: Fri Mar 21, 2025 7:39 pm set ramx_ as temp directory ?
You can set ramx_ as temp directory in qlconfig_bas, if you want and always have ramx_ on your system
I don't understand the question.


Post Reply