View Single Post
Old 08-05-2023, 03:10 AM   #71
ownedbycats
Custom User Title
ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.
 
ownedbycats's Avatar
 
Posts: 11,011
Karma: 75555555
Join Date: Oct 2018
Location: Canada
Device: Kobo Libra H2O, formerly Aura HD
Quote:
Originally Posted by Amalthia View Post
Thanks so much for sharing your code and the information about "Action Chains" I didn't know that plugin existed!

My next test is to see if I can run a script to identify fics that haven't been updated in over a certain period of time and mark them as Abandoned.
Set to 365 days:

Code:
program:
now = format_date(today(),'iso');
updated = $$#fanficupdated;
status = $#fanficstatus;

	if
		status=='In-Progress'
		&& days_between(now, updated) ># 365
	then 
		'Abandoned'

	else 
		status
	fi
My personal version marks dormant fics as such after approximately 4 months and changes to 'abandoned' if there's a logged error. (Transient errors like 'site down for maintenance' or cache errors will also toggle it, so resolve those before running the chain.)

Code:
program:
now = format_date(today(),'iso');
updated = $$#fanficupdated;
status = $#fanficstatus;

	if 
		status=='In-Progress'
		&& $#fanficerror
	then 
		'Abandoned'

	elif
		status=='In-Progress'
		&& days_between(now, updated) ># 120
	then 
		'Dormant'

	else 
		status
	fi

Last edited by ownedbycats; 08-05-2023 at 03:43 PM. Reason: Clarified some wordings
ownedbycats is offline   Reply With Quote