forked from pattern-lab/patternlab-php-core
-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathCommand.php
More file actions
42 lines (32 loc) · 758 Bytes
/
Command.php
File metadata and controls
42 lines (32 loc) · 758 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
<?php
/*!
* Console Command Class
*
* Copyright (c) 2014 Dave Olsen, http://dmolsen.com
* Licensed under the MIT license
*
*/
namespace PatternLab\Console;
use \PatternLab\Config;
use \PatternLab\Console;
use \PatternLab\Timer;
class Command {
protected $pathPHP;
protected $pathConsole;
/**
* Set-up a default var
*/
public function __construct() {
$this->pathPHP = Console::getPathPHP();
$this->pathConsole = Console::getPathConsole();
}
/**
* See if a particular command matches the one passed via the command line
* @param {String} the command to check
*
* @return {Boolean} the result of the test
*/
public function test($command) {
return ($command == str_replace(":","",$this->command));
}
}