Why does a batch file saying
'del C:\Data\Firefox\Bookmarks\ /q'
not delete the JSON* files from \bookmarks\ ?
or
What batchfile code will delete JSON* files from \bookmarks\ ?
Posted 27 August 2023 - 07:31 AM
Why does a batch file saying
'del C:\Data\Firefox\Bookmarks\ /q'
not delete the JSON* files from \bookmarks\ ?
or
What batchfile code will delete JSON* files from \bookmarks\ ?
Posted 27 August 2023 - 02:38 PM
The command you gave would just delete all files in that folder you specified, and not in subfolders.
To remove files with .json extension, you would do
del /q "C:\Data\Firefox\Bookmarks\*.json"
If you wanted to remove them from subfolders also
del /q /s "C:\Data\Firefox\Bookmarks\*.json"
Edited by pseymour, 27 August 2023 - 02:38 PM.
-- Patrick
Posted 11 September 2023 - 12:50 PM
You code differs from mine by only the position of '/q' - which you have after 'del' and I had at the end of the line.
In a week's time, I will report on the effectiveness of relocating '/q'.
Posted 11 September 2023 - 07:28 PM
It differs by more than that. I also explained what your command does.
-- Patrick
Posted 18 September 2023 - 08:23 PM
The question of subfolders does not arise - all the files I want deleted are in just C:\Data\Firefox\Bookmarks\.
If you are referring to '*.jsonlz4' as another difference, I apologize for not recognizing that.
I misrepresented the code in my batch file - that did include '*.jsonlz4'
Relocating the '/q' has caused no improvement.
Posted 19 September 2023 - 07:46 AM
Relocating the /q would make no difference; I never said it did. Also, now you've specified jsonlz4, which would have been helpful before.
Are you getting any kind of error message?
Edited by pseymour, 19 September 2023 - 07:46 AM.
-- Patrick
Posted Today, 01:49 AM
I apologize for the wild goose chase - I misread the symptoms; my own efforts at deletion were successful but misunderstood.
0 members, 4 guests, 0 anonymous users