सामग्री पर जाएं
-
हमारे न्यूज़लेटर की सदस्यता लें और हमारे सर्वश्रेष्ठ पोस्ट कभी न चूकें। अभी सदस्यता लें!
चौकस्माल.कॉम चौकस्माल.कॉम चौकस्माल.कॉम

हमेशा अपडेटेड ब्लॉग और समाचार

चौकस्माल.कॉम चौकस्माल.कॉम चौकस्माल.कॉम

हमेशा अपडेटेड ब्लॉग और समाचार

  • क्यूआर जनरेटर
  • प्रौद्योगिकी
  • सौंदर्य
  • खेल
  • व्यवसाय
  • ऑटोमोबाइल
  • महिलाओं की रुचियां
  • वित्त
  • कला और मनोरंजन
  • भोजन
  • स्वास्थ्य और कल्याण
  • क्यूआर जनरेटर
  • प्रौद्योगिकी
  • सौंदर्य
  • खेल
  • व्यवसाय
  • ऑटोमोबाइल
  • महिलाओं की रुचियां
  • वित्त
  • कला और मनोरंजन
  • भोजन
  • स्वास्थ्य और कल्याण
बंद करें

खोज

ट्रेंडिंग नाउ:
5 आवश्यक उपकरण जो हर ब्लॉगर को उपयोग करने चाहिए संगीत के रुझान जो इस साल हावी रहेंगे चैटजीपीटी प्रॉम्प्ट - एआई सामग्री और छवि निर्माण प्रवृत्ति घिबली ट्रेंड - वायरल एनीमे-शैली विज़ुअल ट्रेंड
  • क्यूआर जनरेटर
  • प्रौद्योगिकी
  • सौंदर्य
  • खेल
  • व्यवसाय
  • ऑटोमोबाइल
  • महिलाओं की रुचियां
  • वित्त
  • कला और मनोरंजन
  • भोजन
  • स्वास्थ्य और कल्याण
चौकस्माल.कॉम चौकस्माल.कॉम चौकस्माल.कॉम

हमेशा अपडेटेड ब्लॉग और समाचार

चौकस्माल.कॉम चौकस्माल.कॉम चौकस्माल.कॉम

हमेशा अपडेटेड ब्लॉग और समाचार

  • क्यूआर जनरेटर
  • प्रौद्योगिकी
  • सौंदर्य
  • खेल
  • व्यवसाय
  • ऑटोमोबाइल
  • महिलाओं की रुचियां
  • वित्त
  • कला और मनोरंजन
  • भोजन
  • स्वास्थ्य और कल्याण
  • क्यूआर जनरेटर
  • प्रौद्योगिकी
  • सौंदर्य
  • खेल
  • व्यवसाय
  • ऑटोमोबाइल
  • महिलाओं की रुचियां
  • वित्त
  • कला और मनोरंजन
  • भोजन
  • स्वास्थ्य और कल्याण
बंद करें

खोज

ट्रेंडिंग नाउ:
5 आवश्यक उपकरण जो हर ब्लॉगर को उपयोग करने चाहिए संगीत के रुझान जो इस साल हावी रहेंगे चैटजीपीटी प्रॉम्प्ट - एआई सामग्री और छवि निर्माण प्रवृत्ति घिबली ट्रेंड - वायरल एनीमे-शैली विज़ुअल ट्रेंड
  • क्यूआर जनरेटर
  • प्रौद्योगिकी
  • सौंदर्य
  • खेल
  • व्यवसाय
  • ऑटोमोबाइल
  • महिलाओं की रुचियां
  • वित्त
  • कला और मनोरंजन
  • भोजन
  • स्वास्थ्य और कल्याण
होम/प्रौद्योगिकी/Ars Asks: Share your shell and present us your tricked-out terminals!
A retro-themed terminal showing code snippets
प्रौद्योगिकी

Ars Asks: Share your shell and present us your tricked-out terminals!

द्वारा व्यवस्थापक
May 6, 2026 4 Min Read
0


The timer_stop operate additionally has the job of changing the timer right into a human-readable format, and it’s most likely messier than it must be. I’m no developer, although, so that is what Previous Lee settled on after a couple of hours of looking out via examples.

Doing it in fish for folk like me

That’s for bash after I’m ssh’d into one in every of my Linux hosts, however I run fish on MacOS. I’ve a separate fish operate for getting the identical outcomes there, full with gross hacks for turning the measurement into human-readable kind. I made this code, and I’m unapologetic. Witness my cobbled-together StackOverflow-sourced kludge.

operate fish_prompt --description 'Write out the immediate'
    # Save the final standing
    set -l last_status $standing

    # Calculate the command period if obtainable
    set -l cmd_duration ""
    if set -q CMD_DURATION
        # Convert milliseconds to microseconds for extra exact comparability
        set -l duration_us (math "$CMD_DURATION * 1000")

        # Calculate completely different time models
        set -l us (math "$duration_us % 1000")
        set -l ms (math "ground($duration_us / 1000) % 1000")
        set -l s (math "ground($duration_us / 1000000) % 60")
        set -l m (math "ground($duration_us / 60000000) % 60")
        set -l h (math "ground($duration_us / 3600000000)")

        # Format period string
        if take a look at $h -gt 0
            set cmd_duration (string be part of '' "(" $h "h" $m "m)")
        else if take a look at $m -gt 0
            set cmd_duration (string be part of '' "(" $m "m" $s "s)")
        else if take a look at $s -ge 10
            set -l fraction (math "ground($ms / 100)")
            set cmd_duration (string be part of '' "(" $s "." $fraction "s)")
        else if take a look at $s -gt 0
            set cmd_duration (string be part of '' "(" $s "." (printf "%03d" $ms) "s)")
        else if take a look at $ms -ge 100
            set cmd_duration (string be part of '' "(" $ms "ms)")
        else if take a look at $ms -gt 0
            set -l fraction (math "ground($us / 100)")
            set cmd_duration (string be part of '' "(" $ms "." $fraction "ms)")
        else
            set cmd_duration (string be part of '' "(" $us "us)")
        finish
    finish

    # Outline unicode symbols for standing
    set -l checkmark "✓"
    set -l cross "✗"

    # Colours
    set -l regular (set_color regular)
    set -l dark_gray (set_color 555555)
    set -l blue (set_color -o blue)
    set -l pink (set_color pink)
    set -l inexperienced (set_color inexperienced)
    set -l purple (set_color -o purple)

    # First line
    echo # New line
    echo -n -s $dark_gray "["(date +%T)"] $last_status " # Time in brackets and exit standing

    # Standing indicator with exit standing
    if take a look at $last_status -eq 0
        echo -n -s $inexperienced $checkmark
    else
        echo -n -s $pink $cross
    finish

    # Really echo the period
    echo -n -s $dark_gray " $cmd_duration"

    # Do the remainder of the immediate
    echo
    set -l host_color $purple
    echo -n -s $host_color $USER "@" (prompt_hostname) $regular ":" $blue (prompt_pwd) $regular " $ "
finish

A splash of colour

Spending my adolescence immersed in ANSI BBS graphics has most likely made me just a little extra fond of colourful textual content in my terminal than the common frumpy, button-downed admin. Look, I do know some of us really feel that syntax highlighting and colours basically kill comprehension and encourage skimming, however what can I say? I like them and depend on them. Maybe I skim an excessive amount of, however so be it. You possibly can take my colourful shell instruments from my chilly, lifeless arms.

To that finish, I lean on just a little program referred to as GRC (for Generic Colorizer) so as to add highlighting and coloration to different instruments. It’s broadly obtainable and works with none further configuration.

Nothing unsuitable with just a little colour!

Lee Hutchinson

Nothing unsuitable with just a little colour!

Lee Hutchinson


Image showing the before and after of using ip a with ping

Nothing unsuitable with just a little colour!

Lee Hutchinson

There’s a little bit of aliasing (which I hold in .bash_aliases like a great citizen) to make colourful output the defaults on some frequent instructions:

    alias ls="ls --color=auto"
    alias ll="ls -AlFh --group-directories-first"
    alias df="grc df -h"
    alias du='grc du -h'
    alias free="grc free -h"
    alias ping='grc ping'
    alias traceroute="grc traceroute"
    alias ip='grc ip'

I’m additionally a giant fan of creating my numbers human-readable, and the -h change is subsequently utilized liberally.

(Do notice that wrapping instructions like ip in GRC can typically do bizarre issues when you’re piping its output into one thing else. Use warning. Or don’t! It’s your pc, knock your self out!)

The terminal itself

Sharp-eyed readers will notice from the screenshots that I’m utilizing MacOS’s Terminal.app for my terminal program, regardless of there being much better choices. I suppose the excuse I’ve is that I’m comfortable with Terminal.app and nothing has pulled me off of it. I’ve test-driven the standard suspects—Ghostty, Alacritty, the mighty iTerm2 with its superior tmux windowing integration, and even fancy new reinterpretations of the terminal expertise like Warp.

लेखक

व्यवस्थापक

मुझे फॉलो करें
अन्य लेख
एल्यूर
पिछला

SZA's “Yellow Halo” Met Gala Make-up Felt Like Pure Sunshine

अगला

AMD's inventory soars 18% as information heart development pushes income and steering previous estimates

कोई टिप्पणी नहीं! पहले बनें।

जवाब छोड़ें जवाब रद्द करें

आपका ईमेल पता प्रकाशित नहीं किया जाएगा। आवश्यक फ़ील्ड चिह्नित हैं *

विषय

  • एफिलिएट मार्केटिंग (1,101)
  • कला और मनोरंजन (4,300)
  • ऑटोमोबाइल (1,234)
  • सौंदर्य (7,254)
  • व्यवसाय (1,523)
  • कोविड-19 (80)
  • ऑनलाइन पैसे कमाएं (39)
  • वित्त (1,366)
  • भोजन (1,362)
  • गेमिंग (1,374)
  • गूगल एडसेंस (379)
  • स्वास्थ्य और फिटनेस (1,014)
  • पालतू जानवर (165)
  • उत्पाद और समीक्षाएं (1,010)
  • क्यूआर जनरेटर (1)
  • खेल (1,914)
  • प्रौद्योगिकी (29,193)
  • यात्रा और अवकाश (252)
  • महिलाओं की रुचियां (1,420)
  • World (3,242)

टैग

एबीबी उत्पाद एल्यूर ब्यूटी बॉक्स अमेज़न ज्योतिष सौंदर्य बिक्री व्यवसाय व्यापार समाचार सेलिब्रिटी सेलिब्रिटी बाल सेलिब्रिटी नेल्स डोनाल्ड ट्रम्प अर्थव्यवस्था यूरोप विशेषता फुटबॉल बाल राशिफल ईरान इज़राइल मेकअप बाजार मध्य पूर्व नाखून समाचार न्यूज़फ़ीड फिलिस्तीन राजनीति समीक्षा बिक्री बिक्री सेवा खरीदारी खरीदारी गाइड शो के प्रकार राशि के अनुसार राशिफल त्वचा त्वचा की देखभाल खेल प्रौद्योगिकी संयुक्त राज्य यूएस और कनाडा ईरान पर अमेरिका-इज़राइल युद्ध कल्याण विश्व राशि

हाल की पोस्टें

  • Footballer dies after on-field collision
    व्यवस्थापक द्वारा
    November 3, 2026
  • कोरोनावायरस की एक ईएम छवि।
    चीन में वायरल निमोनिया के प्रकोप का नया कोरोनावायरस हो सकता है स्पष्टीकरण
    व्यवस्थापक द्वारा
    14 जनवरी, 2020
  • कोरोनावायरस की एक ईएम छवि।
    चीन में वायरल निमोनिया के प्रकोप का नया कोरोनावायरस हो सकता है स्पष्टीकरण
    व्यवस्थापक द्वारा
    14 जनवरी, 2020
  • कोरोनावायरस की एक कंप्यूटर जनित छवि।
    शिकागो महिला वुहान कोरोनावायरस का दूसरा अमेरिकी मामला
    व्यवस्थापक द्वारा
    31 जनवरी, 2020

खोजें...

प्रौद्योगिकियां

फिग्मा

वास्तविक समय में इंटरफेस को सहयोग और डिजाइन करें।

नोटियन

परियोजनाओं को आसानी से व्यवस्थित करें, ट्रैक करें और सहयोग करें।

डाविंची रिज़ॉल्व 20

पेशेवर वीडियो और ग्राफिक संपादन उपकरण।

इलस्ट्रेटर

सटीक वेक्टर ग्राफिक्स और चित्र बनाएं।

फोटोशॉप

पेशेवर छवि और ग्राफिक संपादन उपकरण।

कॉपीराइट © 2026 Chaukasmaal.com
फेसबुक एक्स-ट्विटर यूट्यूब
Chaukasmaal.com द्वारा संचालित