mirror of
https://github.com/opdavies/gmail-filter-builder.git
synced 2025-09-04 04:35:33 +01:00
Add generate-filters
This commit is contained in:
parent
d944cf48f2
commit
3fe899f3a3
2 changed files with 17 additions and 1 deletions
15
bin/generate-filters
Executable file
15
bin/generate-filters
Executable file
|
@ -0,0 +1,15 @@
|
|||
#!/usr/bin/env php
|
||||
|
||||
<?php
|
||||
|
||||
use Opdavies\GmailFilterBuilder\Builder;
|
||||
|
||||
if (file_exists(__DIR__.'/../../filters.php')) {
|
||||
$filters = require(__DIR__.'/../../filters.php');
|
||||
} elseif (file_exists(__DIR__.'/../../filters.php')) {
|
||||
$filters = require(__DIR__.'/../filters.php');
|
||||
} else {
|
||||
throw new \Exception('No filters.php file found.');
|
||||
}
|
||||
|
||||
echo new Builder($filters);
|
Loading…
Add table
Add a link
Reference in a new issue