TGTGInsighttelegram intelligenceLIVE / telegram public index
← Python Заметки

TGINSIGHT SIMILAR POSTS

Најди сличен содржај

Изворен канал @pythonotes · Post #421 · 23 мар.

Мы используем 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

Hashtags

Резултати

Пронајдени 22 слични објави

Пребарај: #positivity

当前筛选 #positivity清除筛选
Quiet World 🍁

@QuietWorld · Post #6627 · 02.10.2019 г., 03:53

It's an absolutely naive to say or think that humans are perpetually happy. Even the most positive person will meet his own dark side. Everyone has a shadow; toxic positivity is the recipe to create thick, dense shadow – because you must always wear the mask of happiness to hide other negative emotions and kick them into unconsciousness until it rots and fester into a monster that will come to the surface when you least expect it. Remember that positivity is not about pretending and not about happiness – it's a mindset; it's about assessing the situation, accepting and understanding your feelings and looking to see if there's anything you can do to make the most of the situation. 🤗 Source: Einzelganger & Positively Present #positivity#selfreminder @quietworld🍃

Quiet World 🍁

@QuietWorld · Post #7241 · 29.03.2020 г., 08:12

Today, Tomorrow or Yesterday? You can't avoid conflicts or problems. In fact, they're ESSENTIAL parts of life. Live today. If you worry about what may go wrong in the future, it might not even happen anyway 🤷🏻‍♀. If you keep on thinking about the past, there's no way to bring you back to the past🙍🏻‍♀. It's okay to look into the future to plan, but not okay to simply worry. It's okay to look back in the past and reflect, but it's not okay to stay stucked in the past. Live. Today. 😊 #life#reminder#positivity @quietworld🍃

Quiet World 🍁

@QuietWorld · Post #6626 · 02.10.2019 г., 03:53

"Positive vibes only 🌸" - oh really? good luck with that! I've been using the word positivity and shared lots of positivity quotes – little that I know that the word 'positivity' can mean differently to different people. So, if you haven't heard it yet, let me introduce you to Toxic Positivity – in which I've also been guilty of at times too🥺 Toxic positivity encourages ignoring negative emotions, but true positivity is about accepting all emotions and doing whatever is possible to work through them, understand them and garner more self-awareness. Toxic positivity presents itself as something anyone can do at any time, but positivity is actually a mindset that doesn't often come easily & must be worked at for most people - IT'S A SKILL. In short, toxic positivity is an attempt to force happiness by rejecting any form of undesirable aspect of an event - but be aware that rejecting either good or bad is similar to rejecting 50% of the universe, because the world isn't good vibes only, it's just vibes. I hope these provide you with a clear understanding of what is toxic positivity and what's true positivity is - and in case you need more clarity, I'd post a few more quotes related in my next posts. 😉 Source: Positively Present & Einzelganger #positivity#afterthoughts#selfreminder @quietworld🍃

12
ПретходнаСтраница 1 од 2Следна