Copying a file to a specific location

(imported topic written by andyt001)

Is it possible to create a task that copy a file I upload to the TEM server to a specific location on the client machine? If so, are there any instructions to doing that?

(imported comment written by gks123)

I’ve been using the Windows Software Distribution Wizard to upload files to the bigfix server and then modify the relevance and actionscript to fit my needs.

Here is an example for adding a file on the all users desktop. Hope this helps.

Relevance 1

( name of it = “Win7” ) of operating system

Relevance 2

not exists file “c:\Users\Public\Desktop\shortcut.lnk”

Action

prefetch shortcut.lnk.tmp sha1:0000000000000000000000000000000000000000 size:1234 http://bigfix:52311/Uploads/0000000000000000000000000000000000000000/shortcut.lnk.tmp

extract shortcut.lnk.tmp

wait “{pathname of client folder of site “BESSupport” & “\RunQuiet.exe”}” “{pathname of system folder & “\cmd.exe”}” /c IF NOT EXIST “C:\Users\Public\Desktop\shortcut.lnk” copy __Download\shortcut.lnk “C:\Users\Public\Desktop”

(imported comment written by SergioBenavides)

using Software Distribution Wizard, upload the file, create new task ,and modify the action script to look something like this:

the values in orange will be given by your own file size

// Download all specified files

begin prefetch block

add prefetch item name=9428AC799E3DF919FCE3A67B9FA3AE91413EDE75 sha1=9428ac799e3df919fce3a67b9fa3ae91413ede75 size=13081608 url=SWDProtocol://127.0.0.1:52311/uploads/9428AC799E3DF919FCE3A67B9FA3AE91413EDE75/SAMPLE_FILE.exe.bfswd

end prefetch block

// All SWD files will go into a folder in the clients __BESData folder. This folder gets cleared on every restart.

parameter “baseFolder” = “c:\THIS IS THE PATH YOU WANT”

folder delete “{parameter “baseFolder”}”

folder create “{parameter “baseFolder”}”

// Move files into subfolders and unescape file names

move “__Download/9428AC799E3DF919FCE3A67B9FA3AE91413EDE75” “{parameter “baseFolder”}SAMPLE_FILE.exe”

Could you please advice if there are multiple locations on client machine where files needs to be copied? this is for a linux flavour.