0

I need to return a full directory name from inside a specified directory that contains .default in the folder name. Basically I'm adding a line in a backup script to backup firefox bookmarks, but the profile name is going to be different on every machine and I need a way to find the folder the bookmarks.html file resides without knowing the firefox profile name

I've looked at FIND and FINDSTR but neither seem to be what I need. I also looked at this post: Windows batch file: get folders' path and store them in variable It was closer to what I'm looking for, but I just need a folder name, and to use something like regexp to find it

Any suggestions on commands to look at or strategies to use?

1 Answer 1

3

Found a way to get the results I want:

FOR /D %%G in ("%USERPROFILE%\Application Data\Mozilla\Firefox\Profiles\*.default") DO Echo ***Found folder: %%G
Sign up to request clarification or add additional context in comments.

1 Comment

You can mark your question as answered now, you sly dog you :)

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.