Supported Versions: PHP 4, PHP 5, PHP 7, PHP 8
Repeat a string
str_repeat(string $string, int $times): string
{
$length = Str::length(strip_tags($string)) + 12;
$this->comment(str_repeat('*', $length));
$this->comment('* '.$string.' *');
$this->comment(str_repeat('*', $length));
$length = Str::length(strip_tags($string)) + 12;
$this->comment(str_repeat('*', $length));
$this->comment('* '.$string.' *');
$this->comment(str_repeat('*', $length));
$this->comment(str_repeat('*', $length));
$this->comment('* '.$string.' *');
$this->comment(str_repeat('*', $length));
$this->newLine();
}
$this->comment('* '.$string.' *');
$this->comment(str_repeat('*', $length));
$this->newLine();
}
$hasMutex = $event->mutex->exists($event) ? 'Has Mutex āŗ ' : '';
$dots = str_repeat('.', max(
$terminalWidth - mb_strlen($expression.$command.$nextDueDateLabel.$nextDueDate.$hasMutex) - 8, 0
));
$command = preg_replace("#(php artisan [\w\-:]+) (.+)#", '$1 <fg=yellow;options=bold>$2</>', $command);
$dots = str_repeat('.', max(
$terminalWidth - mb_strlen($expression.$command.$nextDueDateLabel.$nextDueDate.$hasMutex) - 8, 0
));
$command = preg_replace("#(php artisan [\w\-:]+) (.+)#", '$1 <fg=yellow;options=bold>$2</>', $command);
$nextDueDate
), $this->output->isVerbose() && mb_strlen($description) > 1 ? sprintf(
' <fg=#6C7280>%s%s %s</>',
str_repeat(' ', mb_strlen($expression) + 2),
'ā',
$description
) : ''];
), $this->output->isVerbose() && mb_strlen($description) > 1 ? sprintf(
' <fg=#6C7280>%s%s %s</>',
str_repeat(' ', mb_strlen($expression) + 2),
'ā',
$description
) : ''];
$width = min(terminal()->width(), 150);
$dots = max($width - $descriptionWidth - $runTimeWidth - 10, 0);
$this->output->write(str_repeat('<fg=gray>.</>', $dots), false, $verbosity);
$this->output->write("<fg=gray>$runTime</>", false, $verbosity);
$this->output->writeln(
$dots = max($width - $descriptionWidth - $runTimeWidth - 10, 0);
$this->output->write(str_repeat('<fg=gray>.</>', $dots), false, $verbosity);
$this->output->write("<fg=gray>$runTime</>", false, $verbosity);
$this->output->writeln(
public function bootstrap(Application $app)
{
self::$reservedMemory = str_repeat('x', 32768);
static::$app = $app;
{
self::$reservedMemory = str_repeat('x', 32768);
static::$app = $app;
$middleware = Str::of($middleware)->explode("\n")->filter()->whenNotEmpty(
fn ($collection) => $collection->map(
fn ($middleware) => sprintf(' %sā %s', str_repeat(' ', $maxMethod), $middleware)
)
)->implode("\n");
fn ($collection) => $collection->map(
fn ($middleware) => sprintf(' %sā %s', str_repeat(' ', $maxMethod), $middleware)
)
)->implode("\n");
)
)->implode("\n");
$spaces = str_repeat(' ', max($maxMethod + 6 - mb_strlen($method), 0));
$dots = str_repeat('.', max(
$terminalWidth - mb_strlen($method.$spaces.$uri.$action) - 6 - ($action ? 1 : 0), 0
)->implode("\n");
$spaces = str_repeat(' ', max($maxMethod + 6 - mb_strlen($method), 0));
$dots = str_repeat('.', max(
$terminalWidth - mb_strlen($method.$spaces.$uri.$action) - 6 - ($action ? 1 : 0), 0
$spaces = str_repeat(' ', max($maxMethod + 6 - mb_strlen($method), 0));
$dots = str_repeat('.', max(
$terminalWidth - mb_strlen($method.$spaces.$uri.$action) - 6 - ($action ? 1 : 0), 0
));
$dots = empty($dots) ? $dots : " $dots";
$dots = str_repeat('.', max(
$terminalWidth - mb_strlen($method.$spaces.$uri.$action) - 6 - ($action ? 1 : 0), 0
));
$dots = empty($dots) ? $dots : " $dots";
$offset = $terminalWidth - mb_strlen($routeCountText) - 2;
$spaces = str_repeat(' ', $offset);
return $spaces.'<fg=blue;options=bold>Showing ['.$routes->count().'] routes</>';
}
$spaces = str_repeat(' ', $offset);
return $spaces.'<fg=blue;options=bold>Showing ['.$routes->count().'] routes</>';
}
$runTime = number_format((microtime(true) - $this->latestStartedAt) * 1000, 2).'ms';
$dots = max(terminal()->width() - mb_strlen($job->resolveName()) - mb_strlen($runTime) - 31, 0);
$this->output->write(' '.str_repeat('<fg=gray>.</>', $dots));
$this->output->write(" <fg=gray>$runTime</>");
$this->output->writeln(match ($this->latestStatus = $status) {
$dots = max(terminal()->width() - mb_strlen($job->resolveName()) - mb_strlen($runTime) - 31, 0);
$this->output->write(' '.str_repeat('<fg=gray>.</>', $dots));
$this->output->write(" <fg=gray>$runTime</>");
$this->output->writeln(match ($this->latestStatus = $status) {
$segmentLen = mb_strlen($segment, $encoding);
$end = mb_substr($string, $startIndex + $segmentLen);
return $start.str_repeat(mb_substr($character, 0, 1, $encoding), $segmentLen).$end;
}
$end = mb_substr($string, $startIndex + $segmentLen);
return $start.str_repeat(mb_substr($character, 0, 1, $encoding), $segmentLen).$end;
}
public static function repeat(string $string, int $times)
{
return str_repeat($string, $times);
}
{
return str_repeat($string, $times);
}
public function newLine($count = 1)
{
return $this->append(str_repeat(PHP_EOL, $count));
}
{
return $this->append(str_repeat(PHP_EOL, $count));
}
public function repeat(int $times)
{
return new static(str_repeat($this->value, $times));
}
{
return new static(str_repeat($this->value, $times));
}