agentleFS
bxmaximumbxmaximum/bitrix-framework-skills/skills/bitrix-console-commands/SKILL.md

bitrix-console-commands

Skill73 starsChanged 26 days agoMITView on GitHub

Используй для CLI Битрикса bitrix.php: генерация make:*, orm:annotate, свои команды Symfony Console, cron и JSON-вывод. Регистрация в .settings.php и DI по версиям ядра.

The file

Files
SKILL.md

Консоль Битрикса (bitrix.php)

Baseline: main 23.0+ · Verified: main 26.1000.0

Перед PHP-кодом прочитай bitrix-framework, если ещё не читал его в этой задаче. В таблице выбери только нужный rules/*.md; пути относительны каталогу скилла.

cd /var/www/site && php bitrix/bitrix.php list        # или: cd bitrix && php bitrix.php list
php bitrix/bitrix.php help make:service
php bitrix/bitrix.php make:service Post -m vendor.blog -n   # -n: без вопросов
ЗадачаЧитать
Генераторы make:*, наличие в 25.x, пути результатаrules/generators.md
Команды ядра: orm:annotate, messenger:consume, update:*, main:*rules/generators.md
Своя команда, регистрация, cronrules/custom-command.md

Обязательные правила

  • Нужен Symfony Console из Composer: composer.json с symfony/console и composer.config_path в .settings.php (bitrix-settings); иначе bitrix.php выводит "Symfony Console is not installed".
  • DOCUMENT_ROOT определяется из getcwd() и пути скрипта: запускай из корня сайта или bitrix/, а не php /abs/path/bitrix.php из другого каталога.
  • Команды берутся только из .settings.php установленных модулей → console.commands; глобальный /local/.settings.php их не регистрирует.
  • Since main 26.900 команды создаются через ServiceLocator::getInstance()->get($commandClass): доступен DI конструктора. На старом ядре используется new $commandClass(); получай сервис в execute() (bitrix-framework).
  • В cron и CI всегда указывай -n/--no-interaction.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.