Мы используем Makefile думая, что нет альтернатив, что это стандарт и всё такое.
Но make это не запускалка команд, а система сборки. Мы фактически используем его не по назначению.
И на самом деле альтернатива есть! Некоторое время назад я открыл для себя прекрасный инструмент - just. Он решает все проблемы make.
just - это не система сборки как make, это именно исполнитель команд!
Больше никаких Phony Targets и табуляций, привет нормальный синтаксис и передача аргументов!!! 😎
⭐️Что умеет just:
✅ Автодокументирование команд
Не нужно делать отдельную команду с докой, просто добавь комментарий
# команда сборки
build:
...
$ just --list
Available recipes:
build # команда сборки
Команда с именем default запускается по умолчанию если не указано другое, так что я обычно делаю так:
default:
just --list
Теперь просто выполняем just и получаем доку из текущего файла.
✅ Удобная работа с переменными окружения
# загрузить из .env
set dotenv-load
# глобальная переменная
export PYTHONPATH := "./src"
# переменная для команды
test $TESTUNG="true":
pytest
✅ Передача аргументов
build target:
@echo 'Build {{target}}...'
команда запуска
$ just build dev
# Build dev...
✅ Выбор интерпретатора прямо в команде
Пример с инлайн-скриптом на python:
system:
#!/usr/bin/env python3
import platform
print(platform.system())
Эта же функция позволит выполнить скрипт как одну команду вместо перезапуска шела для каждой строки
foo:
#!/usr/bin/env sh
for file in ls .; do
echo $file
done
✅ Выполнение команды в определенной директории. Можно указать как релятивный путь так и абсолютный
[working-directory: 'backend']
build:
docker compose build
Также можно задать рабочую директорию глобально
Там еще много интересного:
- поддержка функций
- автокомплиты и интеграции
- экспрешены
- алиасы команд
- группировка команд
- альтернативы команды под разные ОС
- импорт других just-файлов
- цветной вывод
- ... и другие штуковины!
Так что вперёд - ➡️ читать доку!
Репозиторий: ➡️https://github.com/casey/just
Статья: ➡️https://www.chicks.net/reference/file_formats/just/
ЗЫ. Кажется, на Makefile я уже не вернусь)
#tools
Group: ZombieSquad Community
Members: ~14.09K
💢 Username: @zombiesquadhq
Description:
🔥 Come play the game and earn sunlight, with a chance to score some airdrop rewards!
🏷 Tags: #airdrop
#cryptocurrencies#aichatbot#airdrop#crypto
https://lve.to/k1gt8zxptq
❝☺️I drank way too much last night, thanks for taking me home, you're a lifesaver! ❞
🔗Keep the story going with her: http://openlove.life
#AIgirlfriend#roleplay#AIchatbot#lookbook
🍷❝Dear Principal, I will greatly appreciate your help with my promotion.❞
🍑Chat with spicy teacher: openlove.life
#aichatbot#AI#AIgirlfriend#aiphoto#nsfw
🌟 Discover Twin GPT - The Cutting-Edge AI Communication on Nicegram! 🌟
Exciting news for Nicegram users! The Nicegram team is proud to reveal that the long-anticipated NGC token will power the innovative Twin GPT platform!
Twin GPT is a revolutionary user-owned AI chatbot seamlessly integrated with Nicegram Messenger. Create, customize, and engage in limitless conversations with your AI Twin, all while unlocking extraordinary communication and monetization opportunities using our NGC token ecosystem.
🚀 Are you ready to dive into the world of NGC and Twin GPT on Nicegram?
🔥 Join the Twin GPT Discussion Group to ask questions, share experiences, and connect with other enthusiasts, particularly those intrigued by NGC and Nicegram:Click here to join the discussion group
Keep an eye out for the latest news, updates, and events on Twin GPT and NGC, right here on Nicegram! #TwinGPT#AIChatbot#NGC
❝Unbind me, and I will bring you a surprise.❞
📲Download App and chat with me
🔗http://openlove.life
#girlfriendgpt#aigirlfriend#spicychat#aichatbot#AIphoto
❤️❝I'm your new stepsis, hope we can live peacefully & lovingly together in the future.❞
📲Download App and chat with me 📷🔗http://openlove.life
#girlfriendgpt#aigirlfriend#spicychat#aichatbot#AIphoto
❝Come on, hurry up,
my husband will be home in 15 minutes.❞
🔥Roleplay with her: http://openlove.life
(Choose Neko and chat with her)
#waifu#neko#aichatbot#aigame#roleplay#catgirl
❤️🔥Would you mind coming over and holding my hand?
📲Download App and chat with me
🔗http://openlove.life
#girlfriendgpt#aigirlfriend#spicychat#aichatbot#aiphotography18
OMG, the bath water is too hot! Can you please help me to turn it cold?🔥💧🥵
🔗Let's role play and chat: openlove.life
#aigirlfriend#aichatbot#ArtificialInteligence#ailookbook#aigame#ai