Jump to content

Create predefined directories


Recommended Posts

Hello,
I'm trying to do the following in my workflows but I can't manage it. It seems basic but I'm having trouble...
Could you help me?

I'm trying to do the following: when I type a word in Alfred, it creates a predefined directory tree in the Finder, at the location where I am. 

Many thanks

Link to comment

Welcome to the forum.

 

It may be that @sepulchra can assist: see, for example, this post of his and the thread of which it's part. You may need, though, to be a little clearer about exactly what you mean by "a predefined directory tree". Can you perhaps give a specific example showing what both the root folder and the resulting tree would look like?

 

xste

Link to comment
32 minutes ago, Stephen_C said:

Welcome to the forum.

 

It may be that @sepulchra can assist: see, for example, this post of his and the thread of which it's part. You may need, though, to be a little clearer about exactly what you mean by "a predefined directory tree". Can you perhaps give a specific example showing what both the root folder and the resulting tree would look like?

 

xste

 

Thank you for your welcome and your feedback.

 

Here's a clearer explanation: 


I have a photo folder for my work. Inside, it's sorted by year. And I put photos according to events.


So I want to create a new folder called event 1, for example, and then use alfred to automatically create 5 empty folders in it: 


Here is the aborescence

Photos > 2024 > Event 1 > Légères (folder 1) - Lourdes (folder 2) - Palmarès (folder 3) - Photos (folder 4) - Sélection (folder 5).

 

And ideally, if I can, in light, have a sub-tree with (PNG) and (WebP), that would be absolutely perfect.

 

I'm going to have a look while I wait for the other post you mention.


Thanks

Link to comment
4 minutes ago, sepulchra said:

@Informacyde Stephen is right to flag that other thread. I believe that should do what you are looking for. If you have questions -- it might make sense to jump in that other thread. 

Thanks, I've just looked at it but it doesn't tell me how to do it unfortunately, it just says it's possible, which I suspected.
The shared file no longer looks downloadable

Link to comment

Thank you very much, it works, it's incredible!

I'm looking at how it works but I'm having a bit of trouble. I'm going to persevere and try adding the "PNG" and "WebP" folders to the "light" directory.

It's a shame, though, that Alfred hasn't made it a bit simpler and more accessible for people who don't know much about code.

Link to comment

if you open up the args and vars object if will give you an idea..... try adding what is in my sreenshot below. I really don't code either, so it is just getting to know the objects and what they do. you'll get the hang of it

 

image.thumb.png.be1760e4a4cc784a72e23cd790b7b2a6.png

Edited by sepulchra
Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...