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

Резултати

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

Пребарај: #magnetar

当前筛选 #magnetar清除筛选
Universe Mysteries 🪐

@cosmomyst · Post #503 · 17.11.2025 г., 12:21

🪐 Magnetars like Swift J1822.3−1606, discovered in the constellation Sagittarius, create magnetic fields over a trillion times stronger than Earth's—so intense they can distort atoms and transform empty space itself into a strange state called a “quantum vacuum.” These extreme conditions make magnetars some of the most powerful natural magnets ever found, unleashing bursts of high-energy X-rays and gamma rays that briefly outshine everything nearby. ✨ #magnetar⚡#neutronstar⚡#extremes⚡#nasa⚡#galaxy⚡#stars⚡#astronomy⚡#universe⚡#cosmos⚡#space 👉subscribe Universe Mysteries 👉more Channels ​

Universe Mysteries 🪐

@cosmomyst · Post #484 · 07.11.2025 г., 22:21

🪐 The magnetar PSR J1745−2900, found near the center of our Milky Way close to Sagittarius A*, showcases magnetic fields so intense they can disrupt atoms and twist space itself. Its field strength is estimated at over a quadrillion times higher than Earth's, making PSR J1745−2900 one of the most extreme magnets in the galaxy and a prime example of how magnetars stretch the laws of physics to their limits. ✨ #magnetar⚡#neutronstar⚡#extremes⚡#nasa⚡#galaxy⚡#stars⚡#astronomy⚡#universe⚡#cosmos⚡#space 👉subscribe Universe Mysteries 👉more Channels ​

Universe Mysteries 🪐

@cosmomyst · Post #411 · 12.10.2025 г., 12:21

🪐 Deep in the constellation Carina sits the magnetar 1E 2259+586, a neutron star with a magnetic field so powerful—over 100 trillion times stronger than Earth's—that it can twist and shatter its own crust. When this happens, it releases bursts of high-energy X-rays and gamma rays, briefly outshining entire galaxies before fading back into cosmic silence. ✨ #magnetar⚡#neutronstar⚡#extremes⚡#nasa⚡#galaxy⚡#stars⚡#astronomy⚡#universe⚡#cosmos⚡#space 👉subscribe Universe Mysteries 👉more Channels ​

Universe Mysteries 🪐

@cosmomyst · Post #112 · 10.08.2025 г., 16:11

🪐 In the constellation Ophiuchus, the neutron star PSR J1846–0258 stunned astronomers when it suddenly switched from behaving like a typical pulsar—flashing regular radio waves—to emitting powerful X-ray bursts, a feature seen in "magnetars," which are neutron stars with ultra-strong magnetic fields. This rare identity shift blurs the line between two of the most extreme types of dead stars, revealing the unpredictable and mysterious nature of cosmic objects. ✨ #neutronstar⚡#magnetar⚡#phenomena⚡#nasa⚡#galaxy⚡#stars⚡#astronomy⚡#universe⚡#cosmos⚡#space 👉subscribe Universe Mysteries

Universe Mysteries 🪐

@cosmomyst · Post #254 · 11.09.2025 г., 00:11

🪐 The magnetar CXOU J171405.7−381031, found in the supernova remnant CTB 37B, is famous for its exceptionally strong magnetic field—over a thousand trillion times more powerful than Earth's. Such intense magnetism can twist the star’s crust, causing violent starquakes and bursts of high-energy radiation that briefly outshine everything else in its region of space. ✨ #magnetar⚡#supernova⚡#neutronstar⚡#nasa⚡#galaxy⚡#stars⚡#astronomy⚡#universe⚡#cosmos⚡#space 👉subscribe Universe Mysteries ​

Universe Mysteries 🪐

@cosmomyst · Post #415 · 12.10.2025 г., 22:21

🪐 On August 27, 1998, astronomers detected a remarkable gamma-ray burst from the magnetar SGR 1900+14, located about 20,000 light-years away in the constellation Aquila. This event released more than a thousand times the energy of the Sun in just a fraction of a second, making it one of the brightest gamma-ray flashes ever recorded and proving that magnetars—neutron stars with ultra-strong magnetic fields—can unleash explosions powerful enough to briefly outshine entire galaxies. ✨ #gamma-ray-bursts ⚡#magnetar⚡#cosmic-explosions ⚡#nasa⚡#galaxy⚡#stars⚡#astronomy⚡#universe⚡#cosmos⚡#space 👉subscribe Universe Mysteries 👉more Channels ​

Universe Mysteries 🪐

@cosmomyst · Post #460 · 27.10.2025 г., 12:21

🪐 Deep in the constellation Vulpecula, the magnetar 1E 2259+586 unleashes magnetic fields so powerful—over 100 trillion times stronger than Earth's—that they can physically warp the star's crust. When these intense magnetic forces crack the surface, they release bursts of high-energy X-rays and gamma rays, briefly making the magnetar outshine every other X-ray source in its region of space. ✨ #magnetar⚡#neutronstar⚡#extrememagnetism⚡#nasa⚡#galaxy⚡#stars⚡#astronomy⚡#universe⚡#cosmos⚡#space 👉subscribe Universe Mysteries 👉more Channels ​

Universe Mysteries 🪐

@cosmomyst · Post #704 · 07.03.2026 г., 22:21

🪐 The magnetar named J1745−2900, discovered near the center of our galaxy close to Sagittarius A*, has one of the most powerful magnetic fields ever measured—enough to disrupt radio signals and, in theory, even deform atoms into thin strings. This type of neutron star is so incredibly magnetic that its field would erase every credit card on Earth from a distance of half the Moon’s span, making J1745−2900 an extreme natural magnet impossible to recreate in any lab. ✨ #magnetar⚡#neutronstar⚡#extremespace⚡#nasa⚡#galaxy⚡#stars⚡#astronomy⚡#universe⚡#cosmos⚡#space 👉subscribe Universe Mysteries 👉more Channels ​

Universe Mysteries 🪐

@cosmomyst · Post #530 · 30.11.2025 г., 22:21

🪐 The magnetar 1RXS J170849.0–400910, located about 18,000 light-years away in the constellation Ophiuchus, is known for its titanic magnetic field, which can reach over 100 trillion times the strength of Earth's. This intense magnetism is so powerful that it can twist the star's crust, triggering sudden bursts of X-rays and gamma rays—brief flashes that outshine entire regions of space before fading into darkness. ✨ #magnetar⚡#Xrays⚡#Ophiuchus⚡#nasa⚡#galaxy⚡#stars⚡#astronomy⚡#universe⚡#cosmos⚡#space 👉subscribe Universe Mysteries 👉more Channels ​