Feature Request : add option to adept_loan_mgt to remove expired loans from list #24

Closed
opened 2026-04-03 12:48:11 +02:00 by bassklampfe · 2 comments

I.e. remove the related xml files from .config/adept/loans/

I.e. remove the related xml files from .config/adept/loans/
Owner

Hello,

I'll not add this option because there is already options to list, return and remove loaned books.
I prefer that user do it manually with understand of what he want than automagically.

Thanks for reporting new ideas.

Grégory

Hello, I'll not add this option because there is already options to list, return and remove loaned books. I prefer that user do it manually with understand of what he want than automagically. Thanks for reporting new ideas. Grégory
Author

@soutade : well, then I'll need to create me a helper script. In onleihe.de expired books are automatically returned, so there is no need to interact with the library service. I just wanted to clean up the list.
This is my script (in bash)

#!/bin/bash
IFS=$'\n' books=( $(adept_loan_mgt -l | fgrep 'Expired') )
for book in "${books[@]}"
do
	id="${book%% *}"
	echo "id='${id}' book='${book}'"
	adept_loan_mgt -v -r "${id}"
done

Big thanks for libgourou !

@soutade : well, then I'll need to create me a helper script. In onleihe.de expired books are automatically returned, so there is no need to interact with the library service. I just wanted to clean up the list. This is my script (in bash) ```sh #!/bin/bash IFS=$'\n' books=( $(adept_loan_mgt -l | fgrep 'Expired') ) for book in "${books[@]}" do id="${book%% *}" echo "id='${id}' book='${book}'" adept_loan_mgt -v -r "${id}" done ``` Big thanks for libgourou !
Sign in to join this conversation.
No Label
2 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: soutade/libgourou#24
No description provided.