Мы используем 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
News: Finance Minister calls for nationwide #fuel conservation as gov’t considers further restrictions
#Ethiopia’s Finance Minister, #Ahmed_Shide, has urged consumers across the country to use fuel “with high conservation,” warning that additional measures aimed at curbing fuel consumption are currently under study.
The call came as the Ministry of Finance announced a new adjustment to domestic #petroleum prices, increasing fuel costs by up to 10 Birr per liter while warning that legal action has begun against entities accused of selling subsidized fuel above government-mandated prices.
In a briefing to journalists, Ahmed said the government is reminding all fuel users to exercise strict conservation. “We want to remind all fuel users that they must use fuel with high conservation,” he said, adding that additional measures currently under review will be announced to the public in the near future.
According to the ministry, the revised prices ……
Read more: https://addisstandard.com/?p=55769
News: #US. issues temporary waiver for #Iranian oil shipments already in transit
The Office of Foreign Assets Control (#OFAC) has issued a time-limited authorization allowing the delivery and sale of Iranian-origin crude oil and #petroleum products that were already loaded onto vessels before 20 March 2026.
In a notice released under “General License U,” the office, part of the U.S. Department of the Treasury, said transactions ordinarily prohibited under U.S. sanctions will be permitted if they are “incident and necessary” to the completion of shipments already in transit by the cutoff date.
The authorization allows activities including the sale, transport, and offloading of such cargoes until 19 April 2026, after which the standard sanctions regime resumes in full.
The measure does not lift broader sanctions on Iran but provides a narrow window to conclude pre-existing .....
https://www.facebook.com/AddisstandardEng/posts/pfbid046J7SQDcCLbGA4CpsTCDV5PcRKReRmpZrNkVZnsMQWdtrvsYjWwsQyaGK5gvfDRvl
NNPC Secures $1 Billion Investment
The Nigerian National Petroleum Corporation (NNPC) is set for a major funding round of $1 billion scheduled for December 17, 2024. For more details, visit their official page at NNPC LTD.
#NNPC#Investment#Funding#Oil#Petroleum#Nigeria#Energy#Finance#CorporateNews#December2024#BillionDollarRound
Funding Rounds Update: December 2024
Recent funding announcements highlight significant investments across various industries:
- ATC Managers, LLC: $14M on Dec 19, 2024 - Nationwide private lender.
- Boon: $15.5M on Dec 20, 2024 - AI solutions provider.
- Accelergen Energy: $20M on Dec 19, 2024 - Clean power asset management.
- Backflip AI: $30M on Dec 19, 2024 - AI content creation.
- Justt: $30M on Dec 19, 2024 - Chargeback automation.
- Decart: $32M on Dec 19, 2024 - Consumer AI platform.
- Instant Transport Solution: $35M on Dec 20, 2024 - Transportation technology.
- TBC Bank Uzbekistan: $37M on Dec 20, 2024 - Banking services.
- RiverWoods Exeter: $39.68M on Dec 18, 2024 - Retirement community.
- EPTME: $44M on Dec 16, 2024 - Lifestyle management.
- JET Charge: $44.93M on Dec 19, 2024 - EV charging solutions.
- Pasadena Private Lending: $50M on Dec 19, 2024 - Non-bank lending.
- Earli: $60M on Dec 19, 2024 - Cancer early detection.
- ALLO: $100M on Dec 19, 2024 - Real-world asset trading.
- DP World Group: $100M on Dec 19, 2024 - Logistics management.
- InoBat: $103.62M on Dec 20, 2024 - Sustainable battery production.
- ŌURA: $200M on Nov 19, 2024 - Health monitoring technology.
- Metsä Group: $208.40M on Dec 19, 2024 - Renewable products.
- Collectivus Holdings: $250M on Dec 19, 2024 - Investment management.
- Nigerian National Petroleum Corporation (NNPC): $1B on Dec 17, 2024 - Petroleum services.
#Funding#Investment#AI#Lending#Logistics#CleanEnergy#HealthTech#Batteries#ConsumerAI#EV#Retirement#Finance#Cancer#Sustainability#Transport#Renewables#RealEstate#Tech#NonBank#Petroleum#Automation