Topic "Transfer options should be per-session not global"

Author Message
Anton P.

Guest


Hi Martin,

I requested a few months ago that WinSCP should remember different sets of file permissions depending on the transfer target. (This is so that files transferred into web folders can have global read and folder-execute set by default, whereas other files only have user read set by default.)

You said that this would be too difficult to implement --- fair enough. So I thought I could get round the problem by setting up different profiles, which both logged me in as the same user on the same machine, but which had different settings for file transfers.

Unfortunately I have discovered that Transfer settings (under "Preferences") are global, and cannot be varied across profiles. To me this seems strange; every other section of "Preferences" give settings which do seem global in nature, whereas I would argue that transfer settings are profile-specific.

I request that transfer settings be moved from the global "Preferences" area to the profile-specific area that the user sees when he is prompted to choose a profile.

Thanks!
Advertisements
martin
[View user's profile]
Site Admin
Joined: 2002-12-10
Posts: 24553
Location: Prague, Czechia
Everything what you ask for can be achieved using autoselection of transfer settings presets.
_________________
Martin Prikryl
Anton P.

Guest


Ah yes, I hadn't fully grasped the functionality of Transfer Presets.

However, there is still one thing that I haven't managed to do: trigger a preset when the remote path contains a specified directory which isn't necessarily the current directory.

For example, I want a preset which is triggered when the current remote directory is

foo/bar/public_html

and when it is any subdirectory, such as

foo/bar/public_html/work/June

etc.

I have tried using various forms in the Remote Directory Mask entry, such as "public_html/*" and so on. But I'm afraid my knowledge of UNIX expressions isn't as good as it should be, so I don't know how to say "when public_html forms part of the pathname"! Could you help me here?

Many thanks
Anton
martin
[View user's profile]
Site Admin
Joined: 2002-12-10
Posts: 24553
Location: Prague, Czechia
You need to specify something like "/foo/public_html;/foo/public_html/*". See documentation.
_________________
Martin Prikryl
Guest




Hi Martin,

I tried this, and it works with absolute paths---thanks.

It also works with relative paths, so long as you precede the path by *, as in
public_html; */public_html/*

However, it doesn't work when you omit the first "*/":
public_html; public_html/*

The second mask does not work, and WinSCP reverts back to the default presets when you navigate into a subdirectory of public_html.

Is this by design?
martin
[View user's profile]
Site Admin
Joined: 2002-12-10
Posts: 24553
Location: Prague, Czechia
It is by design, please read documentation:
Quote:
When the mask selects files and it makes sense to select them based on directory, you can extend the mask with path mask. Separate path mask from filename mask by slash.


I.e. If there is not slash in mask, it is matched only against the last path component. If there is slash, all before the slash is matched against the whole path except for its last component.
_________________
Martin Prikryl
Advertisements

You can post new topics in this forum






Search Site

What is WinSCP?

It is award-winning SFTP client, SCP client, FTPS client and FTP client integrated into one software program for file transfer to FTP server or secure SFTP server. [More]

And it's free!

Donate

About donations

$9   $19   $49   $99

About donations

Recommend

WinSCP Privacy Policy

WinSCP License