Go Back   FlashFXP Forums > > > >

! Requests Need a script or some sort of cool .bat file ? Ask here!

Reply
 
Thread Tools Rate Thread Display Modes
Old 01-20-2004, 06:33 AM   #1
odd
Senior Member
ioFTPD Registered User
 
Join Date: Sep 2003
Posts: 273
Default [REQ] schedular credit for group

Is there any person out there that might want to do a little script.
Script is to ppl who needs to set an amount of credits each day/week/month for
a group. Same as ioA's weeklyset but ioA cant set credits for a group.

When time come for group to get new/more credits script should have two options.
1th leave old credits and add new(old+new).
2th erase old credits and add new(old-old+new).
odd is offline   Reply With Quote
Old 01-20-2004, 09:33 AM   #2
wooolF[RM]
Senior Member
ioFTPD Foundation User
 
Join Date: Oct 2003
Posts: 411
Default Re: [REQ] schedular credit for group

Quote:
Originally posted by odd
When time come for group to get new/more credits script should have two options.
1th leave old credits and add new(old+new).
I would like to see something like that too and I think there are more people that wish to see it come true
wooolF[RM] is offline   Reply With Quote
Old 01-20-2004, 10:01 AM   #3
Mouton
Posse Member
Ultimate Scripter
ioFTPD Administrator
 
Join Date: Dec 2002
Posts: 1,956
Default

give_grp_credits.bat:
@echo !change =Admins CREDITS +102400

ioFTPD.ini:
give_grp_credits = 0 0 * 0 EXEC ..\scripts\give_grp_credits.bat

= Sunday midnight, give an additionnal 100MB to all users in group Admins.

0 0 * * would be every day
0 0 1 * would be every month

If you want to remove old credits and only give 100MB, remove the +

@echo !change =Admins CREDITS 102400

Amazing what u can do with a 1 line .bat, isn't it.
Mouton is offline   Reply With Quote
Old 01-20-2004, 10:28 AM   #4
odd
Senior Member
ioFTPD Registered User
 
Join Date: Sep 2003
Posts: 273
Default

Very nice. Thx Mouton thats good enough for me.
odd is offline   Reply With Quote
Old 01-20-2004, 02:02 PM   #5
wooolF[RM]
Senior Member
ioFTPD Foundation User
 
Join Date: Oct 2003
Posts: 411
Default

hrmpf... ez nuf thnx for the "solution" :banana:
wooolF[RM] is offline   Reply With Quote
Old 01-25-2004, 07:05 PM   #6
wooolF[RM]
Senior Member
ioFTPD Foundation User
 
Join Date: Oct 2003
Posts: 411
Default

ioftpd.ini under [Scheduler]
give_grp_credits = 0 0 * * 1 EXEC ..\scripts\give_grp_credits.bat

[00:59] ioSS daystats: Next day=26 & weekday=Monday
[00:59] endOfWeek... displaying wkstats

nothing happend ... I waited for 10 mins more... got this on IRC :
-:: error ::- 01-26-2004 01:00:02 Scheduler event 'give_grp_credits' returned error.




edit : forgot to add that credits were not added to any of the users :x
wooolF[RM] is offline   Reply With Quote
Old 01-26-2004, 04:55 PM   #7
wooolF[RM]
Senior Member
ioFTPD Foundation User
 
Join Date: Oct 2003
Posts: 411
Default

thnx to Mouton's help on IRC I've "fixed" the problem by opening my eyes...

0 0 * * 1 (I'm used to *nix cronjob format) should be 0 0 * 0

also I found out that description of how the scheduler in ioFTPD works is not proper. It should be like this:

# Scheduler
#
# ioftpd cronjob format is x1 x2 x3 x4 where
# x1=minutes
# x2=hours
# x3=day of month
# x4=day of week
wooolF[RM] is offline   Reply With Quote
Reply

Tags
add, credits, group, script, set

Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Forum Jump


All times are GMT -5. The time now is 08:19 AM.

Parts of this site powered by vBulletin Mods & Addons from DragonByte Technologies Ltd. (Details)