Akopia Akopia Services

[Date Prev][Date Next][Thread Prev][Thread Next][Minivend by date ][Minivend by thread ]

Re: Re: [mv] when writeing a file with tag file, can I chmod it 644?



******    message to minivend-users from Mike Heins <mikeh@minivend.com>     ******

Quoting minivend@hq.com.au (minivend@hq.com.au):
> [snip]
> > Using
> > [tag file="/home/httpd/html/test/1.html" op=log interpolate=1]
> > Test Page
> > [/tag]
> 
> >>I think Minivend 4.04 and higher (i.e. Interchange) accepts a
> >>umask=022 parameter. Try that.
> 
> I tried [tag file="/home/httpd/html/test/1.html" op=log umask=022 interpolate=1]
> Test Page
> [/tag]
> 
> Doesn't seem to work with  MiniVend V4.04a but maybe Interchange.... We're upgrading next month... In the mean time I sort of worked a workaround...
> 
> A Cron Job chmoding *.html in the destination directory every minute... Messy
> but works.. OK
> 

Don't forget you can make your own chmod tag (that goes in minivend.cfg or
interchange.cfg):

UserTag chmod Order file mode
UserTag chmod addAttr
UserTag chmod Routine <<EOR
sub {
	my ($file, $mode, $opt) = @_;

	$mode =~ s/^0+//;
	$mode = oct($mode);
	my $status = chmod $mode, $file;
	return '' if $opt->{hide};
	return $status;
}
EOR

Then:

[chmod file="/tmp/testfile" mode=644]

-- 
Akopia, Inc., 131 Willow Lane, Floor 2, Oxford, OH  45056
phone +1.513.523.7621 fax 7501 <heins@akopia.com>

Fast, reliable, cheap.  Pick two and we'll talk.  -- unknown
-
To unsubscribe from the list, DO NOT REPLY to this message.  Instead, send
email with 'UNSUBSCRIBE minivend-users' in the body to Majordomo@minivend.com.
Archive of past messages: http://www.minivend.com/minivend/minivend-list


Search for: Match: Format: Sort by: