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

TGINSIGHT SIMILAR POSTS

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

Изворен канал @pythonotes · Post #169 · 21 окт.

А знаете ли вы, что в Bash есть особая переменная "$_" ? Из описания можно узнать, что в переменную "$_" помещается последний аргумент последней команды. Что-то знакомое? Конечно, в Python есть примерно тоже самое. Мы знаем, что дата первого релиза Bash (8 июня 1989) несколько раньше чем первый релиз Python (20 февраля 1991). Если учесть, что по задумке автора Python это агрегация самых успешных практик отовсюду, можно ли сказать что именно эта фишка к нему пришла из Bash? Ни подтверждения ни опровержения я пока не нашел. Давайте просто считать это совпадением 😉 А как это может быть полезно в Bash? Приведу простой пример, который оценят те, кто часто работает в терминале. Допустим, нам надо создать директорию и зайти в неё. Что обычно делаем? :~$ mkdir foldername :~$ cd foldername :~/foldername$ Как это сделать в одну команду? :~$ mkdir foldername && cd foldername :~/foldername$ Уже лучше, но хочется короче, без повторов. Вот тут и пригодится наша переменная. Напомню, что в неё сохраняется последний аргумент предыдущей команды. :~$ mkdir foldername && cd $_ :~/foldername$ _________________ PS. Символы "&&"" разделяют команды и означают, что требуется выполнить вторую команду только если первая завершилась успешно. #linux#tricks

Резултати

Пронајдени 1,454 слични објави

Глобално пребарување

Linuxgram 🐧

@linuxgram · Post #18468 · 17.04.2026 г., 10:42

📰 New Lenovo Fan Driver, More ASUS Motherboards With Sensor Monitoring For Linux 7.1 All of the hardware monitoring "HWMON" subsystem updates were merged this week for the Linux 7.1 kernel... 🔗 Source: https://www.phoronix.com/news/Linux-7.1-HWMON #kernel#linux

Linuxgram 🐧

@linuxgram · Post #18467 · 17.04.2026 г., 07:55

📰 Russian Baikal CPUs Are Losing Their Place in the Linux Kernel After sanctions, bankruptcy and removal of kernel maintainers, Baikal's unfinished kernel code is being removed. 🔗 Source: https://feed.itsfoss.com/link/24361/17320657/linux-kernel-baikal-cpu-support-removal #kernel#linux

Linuxgram 🐧

@linuxgram · Post #18453 · 16.04.2026 г., 00:42

📰 WQ_AFFN_CACHE_SHARD Merged For Linux 7.1: Significant Win For CPUs With Many Cores Per LLC The workqueue changes merged today for the Linux 7.1 kernel are significant for today's modern high-end processors where there can be many CPU cores per last level cache (LLC / L3 cache). The new WQ_AFFN_CACHE_SHARD affinity scope can reduce some contention on such systems and help achieve greater performance... 🔗 Source: https://www.phoronix.com/news/Linux-7.1-WQ #kernel#linux

Linuxgram 🐧

@linuxgram · Post #18437 · 14.04.2026 г., 21:12

📰 LLM-Assisted Patches For Linux 7.1 May Have Negative Impact On 32-bit Systems Code now merged for the Linux 7.1 kernel may provide some negative performance implications for those still running modern Linux kernels on 32-bit hardware. A fundamental change can present cache line alignment and slab sizing implications for 32-bit Linux OS users but will provide for cleaner code with modern 64-bit computing... 🔗 Source: https://www.phoronix.com/news/Linux-7.1-VFS-Kino-32-bit #kernel#linux

Linuxgram 🐧

@linuxgram · Post #18418 · 13.04.2026 г., 16:32

📰 Rust For Linux 7.1 Bringing Experimental Option That Can Help Performance In advance of the Linux 7.1 merge window opening, Miguel Ojeda sent out all of the Rust feature updates on Friday. This includes bumping the minimum Rust version for building the Linux kernel as well as a new experimental option that can provide better performance for Rust code within the kernel, alongside other updates... 🔗 Source: https://www.phoronix.com/news/Linux-7.1-Rust #kernel#linux

Linuxgram 🐧

@linuxgram · Post #18413 · 13.04.2026 г., 12:54

📰Linux's Power Sequencing PCIe M.2 Driver To Support M.2 Key-E Connectors Merged for the Linux 7.0 kernel was a power sequencing driver for PCIe M.2 connectors as part of an effort to allow describing PCIe M.2 connectors in Device Tree files. For Linux 7.1, that driver is extending support for PCIe M.2 Key E connectors... 🔗 Source: https://www.phoronix.com/news/Linux-7.1-Power-Sequencing #kernel#linux

Linuxgram 🐧

@linuxgram · Post #18406 · 12.04.2026 г., 21:38

📰 Linux Kernel 7.0 Officially Released, This Is What’s New Linux kernel 7.0 is now available for download with new features, enhanced hardware support through new and updated drivers, improvements to filesystems and networking, and much more. 🔗 Source: https://9to5linux.com/linux-kernel-7-0-officially-released-this-is-whats-new #kernel#linux

Linuxgram 🐧

@linuxgram · Post #18405 · 12.04.2026 г., 19:53

📰 Linux Out-Of-Bounds Access Fixed For Unprivileged Users With Specially Crafted Certs An out-of-bounds access within the Linux kernel has existed in mainline the past three years that could be exploited by an unprivileged user submitting a specially crafted certificate to the kernel... 🔗 Source: https://www.phoronix.com/news/Linux-OOB-Special-Certificate #kernel#linux

Linuxgram 🐧

@linuxgram · Post #18400 · 12.04.2026 г., 05:27

📰 The Linux kernel now allows AI-written code, but you're on the hook for it In a world where AI code is entrenched within people's workflows, developers of all walks of life have had to draw a line somewhere. Some places will outright ban AI code, while others will fully embrace it, and each side has its advantages and disadvantages. Well, it turns out that the world of Linux has finally agreed upon where AI code fits within kernel development. Turns out, it's totally fine if you submit AI-generated code to the kernel;... 🔗 Source: https://www.xda-developers.com/linux-kernel-now-allows-ai-written-code/ #kernel#linux

Linuxgram 🐧

@linuxgram · Post #18389 · 10.04.2026 г., 21:03

📰After one of its choppiest preview cycles in years, Linux 7.0 is almost ready Linux 7.0's kernel hasn't had the best of release candidate phases. From the get-go, the release candidates showed more commit activity than usual, which sounds like it should be a good thing, but it really isn't. The release candidates aren't where new features get added; it's where features that have been added undergo testing. Therefore, the more activity a build has, the buggier it is. 🔗 Source: https://www.xda-developers.com/after-one-of-its-choppiest-preview-cycles-in-years-linux-70-is-almost-ready/ #kernel#linux

Linuxgram 🐧

@linuxgram · Post #18386 · 10.04.2026 г., 18:50

📰 VUMFAT File-System Driver Proposed For The Linux Kernel The newest Linux file-system driver proposed for the kernel is... VUMFAT... 🔗 Source: https://www.phoronix.com/news/Linux-VUMFAT-2026 #kernel#linux

Linuxgram 🐧

@linuxgram · Post #18384 · 10.04.2026 г., 18:38

📰 Linux 2026 "Spring Cleaning" To Address Some Code Remnants As Far Back As Linux v0.1 A big kernel patch series was posted today by longtime Linux developer Thomas Gleixner. The set of 38 patches amount to some big time "spring cleaning" with addressing some code remnants still around that originated back in the very early Linux v0.1 kernel while some other code being cleaned up dates back to the Linux 1.3~2.1 kernel series from the 90's... 🔗 Source: https://www.phoronix.com/news/Linux-0.1-LATCH-Cleanup-2026 #kernel#linux

12•••5253545556•••100•••121122
ПретходнаСтраница 54 од 122Следна