Download the PHP package linkrobins/auto-lock without Composer

On this page you can find all versions of the php package linkrobins/auto-lock. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package auto-lock

Link Robins Auto Lock

Locks discussions that have gone quiet, so old threads stop collecting replies nobody is waiting for. Runs on Flarum's own scheduler, with tags you can exempt and a countdown that tells members a discussion is about to close while they can still reply to it.

Flarum 2.x only.

What it does

Once a day is too coarse for a countdown, so the job runs hourly. Every run it looks for discussions whose most recent post is older than the number of days you set, and locks them. A discussion is skipped when it carries one of your exempt tags, when it is already locked, or when it is hidden.

While a discussion is still open, members see a line above the reply box:

This discussion locks in 12 days if nobody replies.

Replying resets the clock, because the countdown is measured from the most recent post. That is the point of showing it: someone who still cares can keep the thread alive, rather than finding out it closed after the fact.

What it does NOT do

Settings

Admin, then Extensions, then Link Robins Auto Lock.

Setting Default What it does
Lock quiet discussions automatically off The master switch. Nothing is locked while this is off.
Days of silence before locking 30 Counted from the most recent post. Minimum 1.
Tags that are never locked none Discussions with any of these tags stay open however quiet they get.
Show a countdown above the reply box on Turn off to lock silently.
Leave a note in the discussion when it locks on Adds one line to the post stream saying the discussion was locked automatically, and after how long.

It ships switched off. Enabling an extension should not silently start locking a forum's back catalogue, so it waits to be asked.

The note left in a locked discussion records the threshold that was in force at the time, so changing 30 days to 90 later does not rewrite the stated reason on discussions already locked under the old rule. The note is an event post, the same kind of row as a rename or a tag change, so it does not bump the discussion back to the top of the list and does not notify anyone.

Requirements

flarum/tags is optional. Without it there are simply no tags to exempt.

Trying it before you trust it

The command is safe to run by hand, and --dry-run reports what it would lock without touching anything:

php flarum linkrobins:auto-lock --dry-run

Worth doing once on an established forum, where the first real run can lock a lot of threads at once.

Before you turn it on

Locking is not free. A support thread earns its value from the replies it collects over time, and search engines send people to old threads for exactly that reason. Locking one means the next person with the same question starts a new thread instead of adding to the answer.

On a young or small forum, necroposting is usually not yet a problem worth solving this way. It is worth having when threads are old enough that reviving them does more harm than good.


All versions of auto-lock with dependencies

PHP Build Version
Package Version
Requires php Version ^8.3
flarum/core Version ^2.0
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package linkrobins/auto-lock contains the following files

Loading the files please wait ...