142
top 18 comments
sorted by: hot top controversial new old
[-] Tau@sopuli.xyz 21 points 1 year ago

:%s/warning/error/gn

You don't even have to touch your mouse

[-] Prunebutt@feddit.de 9 points 1 year ago

Joke's on you: tiling wm

[-] Andrew15_5@mander.xyz 3 points 1 year ago

With sed command you don't have to use mouse either.

[-] Tau@sopuli.xyz 1 points 1 year ago

But you have to use your mouse to switch to a new terminal, assuming you are using vscode for everything else

[-] mexicancartel@lemmy.dbzer0.com 9 points 1 year ago* (last edited 1 year ago)

Ctrl+alt+t

$ sed...

ctrl+d

[-] Andrew15_5@mander.xyz 3 points 1 year ago

You assumption is wrong. I'm a chad that only use terminal and Neovim. I don't need those filthy mouses. I have a touchpad instead that I also rarely use. I have millions of keymaps engraved in my brain, give me a keyboard and a terminal and I will move mountains.

[-] ruckblack@sh.itjust.works 18 points 1 year ago

Except that I need to do 5 minutes of googling every single time I want to use sed

[-] Andrew15_5@mander.xyz 16 points 1 year ago
[-] riodoro1@lemmy.world 2 points 1 year ago

The first requires no skill and does the same thing.

[-] Andrew15_5@mander.xyz 2 points 1 year ago* (last edited 1 year ago)

The first requires using GUI (and several seconds to launch). We don't do that here.

[-] riodoro1@lemmy.world 2 points 1 year ago

I vividly remember posts about X/Wayland supremacy. It mustโ€™ve been a dream

[-] eager_eagle@lemmy.world 3 points 1 year ago* (last edited 1 year ago)

if you're not being paid by the hour, try out clipea.

?? sed command to replace all 'warning' for 'error' in mid.py, in place
[-] jeffhykin@lemm.ee 13 points 1 year ago

sd or nothing. I'm never dealing with sed's slow and out of date regex ever again

[-] DoomBot5@lemmy.world 10 points 1 year ago

Oh look, this one isn't installed on practically every Linux machine in existence

[-] jeffhykin@lemm.ee 1 points 1 year ago

For now ๐Ÿ˜Ž

[-] palordrolap@kbin.social 6 points 1 year ago

You know that sed does more than s///g, right?

Someone even wrote a version of dc (the arbitrary precision RPN desktop calculator) with it. They were clearly insane of course, but it proves that sed is more than just find and replace.

Honourable mention to awk's sub() and gsub() that, at least for basic find/replace, do the same thing. awk is often surprisingly quick.

[-] paholg@lemm.ee 2 points 1 year ago

I just learned that the Mac version of sed requires a backup file for the -i flag, making it really hard to write cross-platform scripts that use it.

[-] Presi300@lemmy.world -2 points 1 year ago

You're a monster of you actually like regex more than just opening a full text editor. I'd open visual studio and use it to give the text I need before I touch sed

this post was submitted on 17 Nov 2023
142 points (94.9% liked)

linuxmemes

22622 readers
796 users here now

Hint: :q!


Sister communities:


Community rules (click to expand)

1. Follow the site-wide rules

2. Be civil
  • Understand the difference between a joke and an insult.
  • Do not harrass or attack users for any reason. This includes using blanket terms, like "every user of thing".
  • Don't get baited into back-and-forth insults. We are not animals.
  • Leave remarks of "peasantry" to the PCMR community. If you dislike an OS/service/application, attack the thing you dislike, not the individuals who use it. Some people may not have a choice.
  • Bigotry will not be tolerated.
  • These rules are somewhat loosened when the subject is a public figure. Still, do not attack their person or incite harrassment.
  • 3. Post Linux-related content
  • Including Unix and BSD.
  • Non-Linux content is acceptable as long as it makes a reference to Linux. For example, the poorly made mockery of sudo in Windows.
  • No porn. Even if you watch it on a Linux machine.
  • 4. No recent reposts
  • Everybody uses Arch btw, can't quit Vim, <loves/tolerates/hates> systemd, and wants to interject for a moment. You can stop now.
  • 5. ๐Ÿ‡ฌ๐Ÿ‡ง Language/ัะทั‹ะบ/Sprache
  • This is primarily an English-speaking community. ๐Ÿ‡ฌ๐Ÿ‡ง๐Ÿ‡ฆ๐Ÿ‡บ๐Ÿ‡บ๐Ÿ‡ธ
  • Comments written in other languages are allowed.
  • The substance of a post should be comprehensible for people who only speak English.
  • Titles and post bodies written in other languages will be allowed, but only as long as the above rule is observed.
  • ย 

    Please report posts and comments that break these rules!


    Important: never execute code or follow advice that you don't understand or can't verify, especially here. The word of the day is credibility. This is a meme community -- even the most helpful comments might just be shitposts that can damage your system. Be aware, be smart, don't remove France.

    founded 2 years ago
    MODERATORS