Skip to content

Various improvements#181

Merged
friendly-bits merged 16 commits into
lynxthecat:masterfrom
friendly-bits:various_improvements
Jun 6, 2025
Merged

Various improvements#181
friendly-bits merged 16 commits into
lynxthecat:masterfrom
friendly-bits:various_improvements

Conversation

@friendly-bits

@friendly-bits friendly-bits commented Jun 3, 2025

Copy link
Copy Markdown
Collaborator

This PR is mainly about code maintenance and bugfixes.

Among other things, this fixes a bug with files .abl-extract_blocklist, abl-conf-script not removed when adblock-lean is paused.
Also this adds the .gitattributes file as discussed in #93.

Comment thread adblock-lean
Comment thread adblock-lean
Comment thread usr/lib/adblock-lean/abl-lib.sh
@friendly-bits

Copy link
Copy Markdown
Collaborator Author

Hi @lynxthecat, reminding about this PR.

@lynxthecat

Copy link
Copy Markdown
Owner

At this line here:

Should we add a comment along the lines: "Unable to suggest a suitable preset. Please pick your own."?

@friendly-bits

Copy link
Copy Markdown
Collaborator Author

At this line here:

Should we add a comment along the lines: "Unable to suggest a suitable preset. Please pick your own."?

${preset} will be empty string if get_def_preset() failed, most likely because we failed to detect total memory capacity of the system. In this case, get_def_preset() prints an error message:

''|*[!0-9]*) reg_failure "\$_totalmem has invalid value '${_totalmem}'. Failed to determine system memory capacity."; return 1 ;;

I thought this was sufficient and the user will understand why they are asked to pick a preset. If you think we should add an extra message, no problem.

@lynxthecat

lynxthecat commented Jun 6, 2025

Copy link
Copy Markdown
Owner

Yeah I understood that this would occur at least on the failure to detect memory. I mean perhaps it's obvious enough, but I thought perhaps it might be reassuring that the consequence is not dire and only amounts to inability to suggest suitable preset. Just a suggestion from me - I'll leave it with you whether to add or leave as is.

I don't have any other thoughts or suggestions.

@friendly-bits

Copy link
Copy Markdown
Collaborator Author

All right, I added a log message saying approximately what you suggested (the phrasing is a bit different because this may also occur when setup() is called by the luci app and we need to accommodate that case).

I don't have any other thoughts or suggestions.

Do you mean the whole PR? If so, should we merge?

@lynxthecat

Copy link
Copy Markdown
Owner

All right, I added a log message saying approximately what you suggested (the phrasing is a bit different because this may also occur when setup() is called by the luci app and we need to accommodate that case).

Excellent - I like that better than my own suggestion.

Do you mean the whole PR? If so, should we merge?

Yes I think so!

@friendly-bits friendly-bits merged commit 131025e into lynxthecat:master Jun 6, 2025
@friendly-bits friendly-bits deleted the various_improvements branch June 7, 2025 06:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants