Create folder in BES client root if it does not exist

I’m trying to standardize some local files between our *NIX and Windows servers. I’d like to store these files in a new folder inside the BES client directory. I tried using the following relevance with no luck:

not exists folder (parent folder of client) & "/folderdoesnotexist"

No clients showed up as relevant, so I’m assuming I’m doing something wrong. Can anyone help me out here with where I’m going wrong?

In addition to this, for the machines where this will eventually be relevant, I’m going to create the folder if it doesn’t exist. Would this be the correct syntax for the BigFix Action Script:

folder create {(parent folder of client) & "/folderdoesnotexist"}

Thanks for any help.

A couple of problems with the relevance:

  1. Type mismatch - You are concatenating a folder with a string
  2. Invalid object create - You want to use “folder (string)” not “folder (folder)”

Try this option instead:

not exists folder (pathname of parent folder of client & "/folderdoesnotexist")

The actionscript is failing because of the same type mismatch issue. I suspect you can correct it now, given the above info.

2 Likes

Plus all that is pretty inefficient and platform specific.

Its much easier to do this

not exists folder "folderdoesnotexist" of parent folder of client
2 Likes

I’ve got a new tagline for you, Alan.

AlanM - Optimizing relevance usage one post at a time

:grin:

3 Likes

Got to start somewhere :slight_smile:

Ah, that makes sense @steve - also, thanks for the optimization @AlanM.