|
I’m fixing a Perl script at work and I want to rewrite it in ansible so bad
|
# ? Feb 23, 2024 04:13 |
|
|
# ? Jun 9, 2024 10:14 |
|
fresh_cheese posted:yea but its gross who gives a poo poo. if i think i can write something in bash faster than i could write it in a more robust language, i'm going to write it in bash if it needs arrays it needs arrays
|
# ? Feb 23, 2024 04:18 |
|
BobHoward posted:you're writing shell scripts serious enough to version control, ci/cd, and lint vagrant. not my choice.
|
# ? Feb 23, 2024 04:18 |
|
bash has arrays poo poo, bash has associative arrays
|
# ? Feb 23, 2024 04:19 |
|
outhole surfer posted:bash has arrays yeah and they work perfectly fine. the syntax even mostly makes sense who gives a poo poo that it's bash
|
# ? Feb 23, 2024 04:19 |
|
yea, build it slowly and itll be less likely youll rm -rf / somepath/oshitwtf i also substitute ls for rm while developing the loop and then cmd history edit in the rm for the real run
|
# ? Feb 23, 2024 04:36 |
|
i usually debug with echo prefixes
|
# ? Feb 23, 2024 04:39 |
|
Beeftweeter posted:yeah and they work perfectly fine. the syntax even mostly makes sense i have done worse in bash. i wrote a firstboot personalization cloud init thing in bash, and it worked fine dont overengineer poo poo. it only needs what it needs. im just sayin where my limits are, now. to be honest tho, my python looks a lot like my bash lovely
|
# ? Feb 23, 2024 04:40 |
|
outhole surfer posted:i usually debug with echo prefixes gently caress i debugged a nova compute driver with a shitton of printf() no shame
|
# ? Feb 23, 2024 04:42 |
|
is there some other way to debug besides writing print("got here") in random spots
|
# ? Feb 23, 2024 04:48 |
|
Beeftweeter posted:yeah and they work perfectly fine. the syntax even mostly makes sense do you like perl i like perl
|
# ? Feb 23, 2024 04:50 |
|
mycophobia posted:is there some other way to debug besides writing print("got here") in random spots in bash it's more like $ for i in $(gen-shitshow); do echo deal-with-shitshow $i; done deal-with-shitshow dumb_colleague deal-with-shitshow sales_sold_something_we_havent_built_yet deal-with-shitshow ran_out_of_fucks deal-with-shitshow us_east_1
|
# ? Feb 23, 2024 05:00 |
|
matti posted:do you like perl i like perl i don't really know perl. i've edited scripts and muddled my way through with documentation but i've never actually written anything substantial myself
|
# ? Feb 23, 2024 05:14 |
|
i think you would like it
|
# ? Feb 23, 2024 05:14 |
|
matti posted:do you like perl i like perl i find perl terrifying regex doesnt bother me its the 30 different ways to do the same thing that bothers me dowloading crap from cpan and running it as root also seems like a bad idea
|
# ? Feb 23, 2024 05:17 |
|
matti posted:i think you would like it probably, i just haven't had a reason to pick it up i guess. it wasn't all that hard to edit so i guess i could probably learn it relatively quickly
|
# ? Feb 23, 2024 05:19 |
|
Amethyst posted:my 2018 dell xps 13 is dying. is anyone running ubuntu on a 2024 xps 13? Preferably jammy i have an xps 13, it's got only got 2 usb ports and you're supposed to be using one of them to charge the laptop with
|
# ? Feb 23, 2024 05:20 |
|
iirc the 2024 xps has a dedicated bing ai button too lol
|
# ? Feb 23, 2024 05:22 |
|
oh and the 2nd port is where your usbc yubikey goes
|
# ? Feb 23, 2024 05:23 |
|
Beeftweeter posted:iirc the 2024 xps has a dedicated bing ai button too lol what the sam hill?
|
# ? Feb 23, 2024 05:24 |
|
fresh_cheese posted:what the sam hill? capacitive f-keys too
|
# ? Feb 23, 2024 05:28 |
|
they guy who made the good XPSes left Dell and they turned bad pretty much immediately
|
# ? Feb 23, 2024 05:29 |
|
goddammit redmond you can remap it to something useful like a “paste rickroll url” or similar, right ?
|
# ? Feb 23, 2024 05:30 |
|
i assume it's just Super_R with new branding
|
# ? Feb 23, 2024 05:32 |
|
anyway the xps13 i've got is from 2021 or 2022 or thereabouts so it doesn't have that
|
# ? Feb 23, 2024 05:33 |
|
fresh_cheese posted:goddammit redmond nope the article specifies that you can't. lol https://arstechnica.com/gadgets/2024/01/the-dell-xps-laptop-as-we-know-and-love-it-is-no-more/
|
# ? Feb 23, 2024 05:36 |
|
burn it all
|
# ? Feb 23, 2024 05:54 |
|
Progressive JPEG posted:i assume it's just Super_R with new branding I assume it generates Windows-C
|
# ? Feb 23, 2024 05:59 |
|
Beeftweeter posted:probably, i just haven't had a reason to pick it up i guess. it wasn't all that hard to edit so i guess i could probably learn it relatively quickly that's how perl sucks its victims in, yes
|
# ? Feb 23, 2024 06:21 |
|
BlankSystemDaemon posted:That's a toast I'll drink to; I was actually thinking about having a finger of Bushmmills. i was killing off the heel of a bottle of Loch Lomond 12 Inchmurrin, which is their fruity style. Loch Lomond is an interesting distillery, they have a couple of different and unique stills that allow them to make various styles of whisky (light, heavy, smokey, fruity, etc.) all in house. I liked the Inchmurrin but I think I prefer the "regular" Loch Lomond. Still, not a bad whisky.
|
# ? Feb 23, 2024 07:12 |
|
Beeftweeter posted:
wtf is going on to the right of the backspace key
|
# ? Feb 23, 2024 07:20 |
|
shackleford posted:wtf is going on to the right of the backspace key gotta upgrade to the more premium trim
|
# ? Feb 23, 2024 07:22 |
|
mycophobia posted:is there some other way to debug besides writing print("got here") in random spots set -x
|
# ? Feb 23, 2024 07:29 |
|
shackleford posted:wtf is going on to the right of the backspace key i think its a fingerprint reader. the one on my chromebook doesn't look that stupid but it does just look like a key, not infrared filtered looking like the touchid sensor on macbooks. and it's in the same spot
|
# ? Feb 23, 2024 08:57 |
|
fresh_cheese posted:i find perl terrifying if you think Perl is scary, never try to format a string in python, the number of different ways to do it might scar you for life
|
# ? Feb 23, 2024 12:16 |
|
Beeftweeter posted:that reminds me Far too complicated for the kind of one-liner I do late into the day. Also, using ls in the for is a hanging offense where I live.
|
# ? Feb 23, 2024 13:48 |
|
yeah don't use ls in scripts what the hell re:perl, i don't like perl because i only "use" it when i have to fix a script that's been working fine since 1994, because some dumbass idiot changed an api workflow or some poo poo otoh, i like perl because a script that's been working since 1994 still works exactly the same in tyool 2024 on the latest perl version, unlike almost every modern script language. there's no version dependecy hell, you install perl and it runs your script from 30 years ago
|
# ? Feb 23, 2024 14:10 |
|
not about to write any perl, but it is basically perfect for the purpose of zero-friction drop-in for the likes of bash and awk, only way more competently done (e.g. certainly more hygienic about random string interpolation than bash), and if there's some detail of a unix'ish environment you need to deal with perl will almost certainly be at least as competent as any alternative at it. that said the world had been better had tcl just won out as the scripting/tooling/configuration format.
|
# ? Feb 23, 2024 14:19 |
|
Cybernetic Vermin posted:that said the world had been better had tcl just won out as the scripting/tooling/configuration format. every time i have to write tcl (which i sometimes do, because it did kinda win in certain niches), i have to google for information about how to do poo poo. all this ever seems to find is mailing list arguments between tcl graybeards which got copied into a wiki article and called "documentation". not really the language's fault but trying to suss the truth out of that pile of noise is an extremely irritating way to try to learn how to write tcl, lol also tcl somehow manages to be less straightforward than perl. idk, maybe my brain is broke, but i just don't get tcl or see why anyone would want to use it. my go-to plang is python3 because even though it sucks, the magnitude of its suckage is mostly less than perl
|
# ? Feb 23, 2024 14:44 |
|
|
# ? Jun 9, 2024 10:14 |
spankmeister posted:i was killing off the heel of a bottle of Loch Lomond 12 Inchmurrin, which is their fruity style. Loch Lomond is an interesting distillery, they have a couple of different and unique stills that allow them to make various styles of whisky (light, heavy, smokey, fruity, etc.) all in house. I liked the Inchmurrin but I think I prefer the "regular" Loch Lomond. Still, not a bad whisky. I'm a pretty basic bitch when it comes to whisky; I almost always prefer whiskey, because I generally find it more drinkable without needing it to be on the rocks - and if you have to have rocks in, why even drink it?
|
|
# ? Feb 23, 2024 15:28 |