Merge branch 'release/0.0.11.4'
This commit is contained in:
commit
e482c0df9e
4 changed files with 6 additions and 2 deletions
|
@ -43,12 +43,14 @@ class ParseCachedWebMentions extends Command
|
||||||
foreach ($HTMLfiles as $file) {
|
foreach ($HTMLfiles as $file) {
|
||||||
if ($file->getExtension() != 'backup') { //we don’t want to parse.backup files
|
if ($file->getExtension() != 'backup') { //we don’t want to parse.backup files
|
||||||
$filepath = $file->getPathname();
|
$filepath = $file->getPathname();
|
||||||
|
$this->info('Loading HTML from: ' . $filepath);
|
||||||
$html = $filesystem->get($filepath);
|
$html = $filesystem->get($filepath);
|
||||||
$url = $this->URLFromFilename($filepath);
|
$url = $this->URLFromFilename($filepath);
|
||||||
$microformats = \Mf2\parse($html, $url);
|
$microformats = \Mf2\parse($html, $url);
|
||||||
$webmention = WebMention::where('source', $url)->firstOrFail();
|
$webmention = WebMention::where('source', $url)->firstOrFail();
|
||||||
$webmention->mf2 = json_encode($microformats);
|
$webmention->mf2 = json_encode($microformats);
|
||||||
$webmention->save();
|
$webmention->save();
|
||||||
|
$this->info('Saved the microformats to the database.');
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -41,6 +41,7 @@ class ReDownloadWebMentions extends Command
|
||||||
{
|
{
|
||||||
$webmentions = WebMention::all();
|
$webmentions = WebMention::all();
|
||||||
foreach ($webmentions as $webmention) {
|
foreach ($webmentions as $webmention) {
|
||||||
|
$this->info('Initiation re-download of ' . $webmention->source);
|
||||||
$this->dispatch(new DownloadWebMention($webmention->source));
|
$this->dispatch(new DownloadWebMention($webmention->source));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -5,8 +5,6 @@ namespace App\Providers;
|
||||||
use App\Tag;
|
use App\Tag;
|
||||||
use App\Note;
|
use App\Note;
|
||||||
use Validator;
|
use Validator;
|
||||||
use App\WebMention;
|
|
||||||
use App\Observers\WebMentionObserver;
|
|
||||||
use Illuminate\Support\ServiceProvider;
|
use Illuminate\Support\ServiceProvider;
|
||||||
|
|
||||||
class AppServiceProvider extends ServiceProvider
|
class AppServiceProvider extends ServiceProvider
|
||||||
|
|
|
@ -1,5 +1,8 @@
|
||||||
# Changelog
|
# Changelog
|
||||||
|
|
||||||
|
## Version 0.0.11.4 (2016-09-19)
|
||||||
|
- Better console output for the new webmention commands
|
||||||
|
|
||||||
## Version 0.0.11.3 (2016-09-19)
|
## Version 0.0.11.3 (2016-09-19)
|
||||||
- Simplify how we filter/cache reply html
|
- Simplify how we filter/cache reply html
|
||||||
- Better handling of webmention reply HTML cache
|
- Better handling of webmention reply HTML cache
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue