#unix
1 messages ยท Page 16 of 1
i mean like on vm fine but on pc no work, kill my pc
is that possable?
What do you mean on your pc? Do you mean dual booting? Do you mean erasing your entire system and installing your new operating system?
Worst can happen if things goes bad while dual booting is you partitioning things wrong and you end up erasing your current system , and mess up the new system installation
or if installing your new operation system as your only main operating system , you can mess it up , and not succeed installing it , and you end up erasing your old system, and no system at all on your machine!
So I don't have to worry about messing up bios, cool
I was scared because I have to make a kirnal and ppl say that can mess up pcs
git cli question.
I usually use vim and compare with old versions of a file inside my editor. But sometimes I would like to just cat an old state of a file. I can do for example:
$ echo HEAD~1400:.envrc | git cat-file --batch
But this command is quite long, isn't there a shorter version?
Aha! git cat-file -p HEAD~1400:.envrc
git show HEAD~1400:.envrc
oh ๐ thanks!
I see myself as git expert but never noticed git show ๐
It's such a big software ๐ฎ
i'm currently transferring files from a remote server using scp -r, but it's a bit slow. does anyone know of a faster way to transfer files between a local machine and a remote server, other than scp? Looking for something that can handle large directories more efficiently
I would try rsync, it's more efficient especially for many smallish files

i tried, but its so hard to set it up
i had to resort to asking chatgpt
o.O Isn't it just rsync source target?
What OS are you on?
windows 10
WSL or not?
With WSL installing rsync should just work by doing sudo apt install rsync
tar(or zip) file, scp file, untar(or unzip) file ๐
Single file is transmitted faster
You can compress the files and send or use pscp which transfers files in parallel
i used winscp instead
running the latest Python release on BSD
The Python ecosystem on BSD is highly deprecated. The current default version of Python running on FreeBSD is Python 3.11
3.11 is still supported (until 2027). It's also the version on the current Debian stable (bookworm)
the photo above is FreeBSD's pkg package manager. Similar to apt on standard Linux distributions. It's .... ok lol but not seamless with a basic pkg install <package> command for anything in the Python ecosystem
Is MacOS a derivative of the Unix tree 
Hey, you should re-ask your question in an off-topic channel as your post is outside the scope of this channel.
ohh okay, i thou its all Unix!!
whereโs off-topic btw ?
Please read the channel's description 
!ot
#ot2-never-nesterโs-nightmare
Please read our off-topic etiquette before participating in conversations.
https://www.levenez.com/unix/unix.pdf don't open this with Adobe reader
I forgot about the tree visual. And of all of them itโs a derivative of BSD ๐
Registered UNIX system. Even recently.
I just reinstalled Raspberry Pi OS (Debian 12 Bookworm) and I'm trying to compile Python 3.11.11 via pyenv to (1) have my own user installation and (2) use my locally built version of SQLite3MultipleCiphers present in /usr/local/lib (specifically libsqlite3mc.so.0.0.0, with a symlink for libsqlite3.so). I installed the build dependencies, libsqlite3-dev included: sh sudo apt-get install build-essential gdb lcov pkg-config \ libbz2-dev libffi-dev libgdbm-dev libgdbm-compat-dev liblzma-dev \ libncurses5-dev libreadline6-dev libsqlite3-dev libssl-dev \ lzma lzma-dev tk-dev uuid-dev zlib1g-dev libmpdec-dev
But despite this, pyenv couldn't build with SQLite support: sh $ pyenv install 3.11 Downloading Python-3.11.11.tar.xz... -> https://www.python.org/ftp/python/3.11.11/Python-3.11.11.tar.xz Installing Python-3.11.11... Traceback (most recent call last): File "<string>", line 1, in <module> File "/home/thegamecracks/.pyenv/versions/3.11.11/lib/python3.11/sqlite3/__init__.py", line 57, in <module> from sqlite3.dbapi2 import * File "/home/thegamecracks/.pyenv/versions/3.11.11/lib/python3.11/sqlite3/dbapi2.py", line 27, in <module> from _sqlite3 import * ModuleNotFoundError: No module named '_sqlite3' WARNING: The Python sqlite3 extension was not compiled. Missing the SQLite3 lib? Installed Python-3.11.11 to /home/thegamecracks/.pyenv/versions/3.11.11 I previously set this up on Bullseye, and I thought these were the only steps I needed... Any suggestions on solving this?
Huh, after removing the symlink and building/installing the original SQLite 3.49.1 from source, it compiled correctly: sh $ sudo make install /usr/bin/install libsqlite3.so "/usr/local/lib" Setting up libsqlite3.so version symlinks... lrwxrwxrwx 1 root root 20 Mar 30 20:40 libsqlite3.so -> libsqlite3.so.3.49.1 lrwxrwxrwx 1 root root 20 Mar 30 20:40 libsqlite3.so.0 -> libsqlite3.so.3.49.1 -rwxr-xr-x 1 root root 4879992 Mar 30 20:40 libsqlite3.so.3.49.1 [...] $ pyenv install -f 3.11 Downloading Python-3.11.11.tar.xz... -> https://www.python.org/ftp/python/3.11.11/Python-3.11.11.tar.xz Installing Python-3.11.11... Installed Python-3.11.11 to /home/thegamecracks/.pyenv/versions/3.11.11 Following that, prepending /usr/local/lib to /etc/ld.so.conf and sudo ldconfig got my Python to start using 3.49.1, and then I removed the above SQLite library and added back my symlink to SQLite3MultipleCiphers.
Not sure why it didn't initially work with sqlite3mc symlinked, but oh well ๐
Does anyone have any experience with packaging python with nix or writing nix derivations for python programs
Prob the Python dev community. The ones who help build the Python ecosystem. Is there a version of Unix out there to poke around with? Toy projects
Anyone here using module (i.e. module load) system to distribute python environment?
Thinking about if there is any known good way to do it, or do's and don'ts.
You mean like module as in the HPC tool?
module avail python should show you the options to choose from, and then you'd just module load python/x.y.z cuda/x.y example/x.y and module save somename.. been a while since I touched any of that so I'm not sure what the latest python available will be
I guess a best practice might be to use a 'group' that includes the tools you want, rather than al a carte?
Which I think you can see with module avail -t?
I never had to set up my own module collection from scratch, hopefully there's a nice repo to bootstrap from these days?
Idk if this is python specific or if this even is the right channel, but is it normal for code like this to completely freeze my system to where i have to force restart it with the power button?
from functools import reduce
def prime_f_rec(n):
def rec_format(factor):
res = 2
for _ in range(factor-2):
res += 1
return res
factors = prime_factors(n)
return reduce(lambda x,y:x*y, [rec_format(factor) for factor in factors])
def prime_factors(n):
factors = []
while n % 2 == 0:
factors.append(2)
n = n // 2
for i in range(3, int(n**0.5) + 1, 2):
while n % i == 0:
factors.append(i)
n = n//i
if n > 2:
factors.append(n)
return factors
for i in range(5000):
assert eval(prime_f_rec(i)) == i
This happens way too often because sometimes when i have to wait on something i'll just open python repl and play with it, and basically crash my computer. The screen still displays but it is fully frozen, and i cannot do anything, not even switch tty.
I use archlinux
lets see... this looks like adventure from Data Structures and Algorithms and problem with complexity on a first glance i think
from functools import reduce
def prime_f_rec(n):
def rec_format(factor):
res = 2
for _ in range(factor-2):
res += 1
return res
factors = prime_factors(n)
# N^2 actions at least
return reduce(lambda x,y:x*y, [rec_format(factor) for factor in factors])
def prime_factors(n):
factors = []
# Log2(N) complexity?
while n % 2 == 0:
factors.append(2)
n = n // 2
# Log2(N) * N of smth? potential infinity of actions can be may be
for i in range(3, int(n**0.5) + 1, 2):
while n % i == 0:
factors.append(i)
n = n//i
if n > 2:
factors.append(n)
return factors
for i in range(5000):
# loop one for 5000
assert eval(prime_f_rec(i)) == i
on my very rought eye, u have potentially here N * Log2(N) * NSmth? actions complexity at least here
With potential N^3 may be?
So... a good thing will be actually just measuring time and seeing if it is performance issue or u created somewhere infinity thing it stucked
remove eval thingy and just measure time for each prime_f_rec(i) calculated
it is supposed to start with small amount of time and gradually increasing calculations in time if is not sticking
import time
for i in range(5000):
start = time.time()
assert eval(prime_f_rec(i)) == i
print(time.time() - start)
if smth is growing in number gets written, with each next loop taking more time than previous... then u just created high in complexity algorithm (and python slowness in calculating such stuff 20-40 times more slower than other languages, plus lack of parallelism do not help a lot)
if number is not growing at all right from a start, then your logic is somewhere faulty and it just stucked in some infinity loop
Ah... Also, open Memory monitor when u launch it
if your RAM jumps to maximum (and i guess all cores can be jumping to max too, but RAM is more interesting)
then u created a fault in algorithm that overflows RAM or created fork bomb (with eval) by accident potentially also
Why are we not questioning the eval() again? Shouldn't that just be throwing an exception when you try to eval an integer?
shrugs. I never used eval practically. Unsafe/impractical thing that is like using GOTO for me
But in theory u can fork bomb stuff with it, so that's why i recommend just in case monitoring RAM usage
TLDR: Monitor PC resources usage for more information, measure time (and remove preferably eval for more sanity)
Hey ๐, I am currently looking to boost my CV, I'm looking for a new job as I'm not getting a permanent role at the company I've been interning at for a year and a half now. My skills are Unix , enterprise Linux, python, docker, Jenkins and kubernetes. Is there more I should learn, does anyone have project ideas? Thanks in advance.
The eval was there from a previous version. It seems one core goes to 100% and my ram usage also continues to go up. I know that eval, and the whole program is slow, but i didn't know that eval can completely freeze up my computer
maybe we're has same goal
Do you have the same skills? Are you also trying to pivot into DevOps?
I can not figure out which file in /etc/ is responsible for bash trying to execute something from a file path that leads nowhere and I want it to stop doing this every time I start terminal. I thought I was looking for a .bash_profile but I don't see one in /etc/. Am I looking in the wrong place?
may be? Commonly it is ~/.bashrc used as a starting point
try to input smth like ls ~/.bash and press Tab many times, u will see in your user profile existing files starting with that name, may be will show .bash_profile too
check ~/.bashrc, ~/.bash_profile, /etc/profile, /etc/profile.d/, /etc/bash.bashrc
~ is your $HOME
those are the ones that come to mind
What distro? It varies a bit.
/etc/bash.bashrc is a thing commonly
man bash should list them also
if you're on *nix, you could try "strace" -- it monitors files that the process opens
or just grep for the file name in everything in /etc
Oh ok, I see it in my home directory and not /etc/, using ls ~/.bash
I'm on Mac OS Catalina terminal
Why would it be in /etc/ for some people?
Uh. Not a Linux. We were probably all mistaken u ask for Linux
No idea how stuff works at macOS
I am aware it is Unix based, but it is not using Linux kernel and should be different. Dunno how much it is different
Oh well it worked anyway. Thx!
~ current user specific one, apps save current user specific configs and temporal files in it
/etc is global one, apps put configs to it
I see
zsh is the default on MacOS and there's a hard-to-find default file at /System/Library/Templates/Data/private/etc/zshrc
Though I think it's just used to create /etc/zshrc? I'd have to dig into it.
Isn't that path the same as /etc/zshrc via macOS path fuckery?
yeah
Is todays Unix super trademark proprietary. Is it still owned by AT&T
No, the name UNIX is owned by "The Open Group" now, which allows use of the term if you conform to its specs.
(Also, that is only enforced for the uppercase variant, you can call anything "unix", AFAIU)
That is a lot to unpack. I figure AT&T would hold a stake in Unix. Itโs a historical brand
Yeah, but it doesn't. It sold it to Novell, which then sold it to the Open Group.
That is unfortunate
which state?
I don't know if it is a bug or not. I am now on Linux. So, I was trying to dual boot Windows and Debian. I don't want to be the bedion on the 1st option because my parents used the PC, so I was paying/trying in the Windows GUI search for other OS (I don't know what they call it). When I escape the Win Gurb, the Debian Gurb pops up, and I boot it to Debian. LOL
I just want to tell someone the experience/ story.
i have it in reverse i think ๐
Linux by default in OS picking in the grub
but if i exit it, then Windows Grub analog can appear
๐ฎ
anyway, for those messy reasons of Windows/Linux grubs...
..i install my OSes to different SSDs
and i make sure to Remove Power Cord Cable from Linux drive during Windows installation
makes sure Windows does not touch my precious Linux
Linux becomes grub aware about Windows, and windows remains working without awarence of linux
since LInux is customizable, easy to adjust grub to whatever desired needs
Ya think so to, win Gurb is old looking.
when u install OSes to different drives
Default "OS grub" is even switchable in Bios configuration to pick which drive is the main/boot one ๐
Is OSes a OS, OR multiple os?
OSes means multiple OS
Oo, cool ๐
:incoming_envelope: :ok_hand: applied timeout to @placid musk until <t:1744310063:f> (10 minutes) (reason: duplicates spam - sent 4 duplicate messages).
The <@&831776746206265384> have been alerted for review.
What happened here ๐
Is anyone in systems engineering. Sysadmin Linux - BSD stuff
Windows too. WSL2 is pretty nice
Please react with โ
to upload your file(s) to our paste bin, which is more accessible for some users.
You can click that green + white checkmark to get it to put it on the paste site for you.
Please react with โ
to upload your file(s) to our paste bin, which is more accessible for some users.
this is the readme.txt
Please react with โ
to upload your file(s) to our paste bin, which is more accessible for some users.
Cool. What's the question?
this is on python 3.12 i am on windows 10. There's also a way to mount iso image on window and use the tool to go through the directory using the the python script. my question is how can i lock python down for user that are not admin? i am looking through reddit right now. i don't want users to have access to python.
You can use Group Policy (gpedit.msc) to prevent users from running specific binaries
There should be a thing under Computer Configuration > Administrative Templates > System called "Don't run specified Windows applications"
There's also a thing these days built in called AppLocker you can do it from, but I'm not very experienced with it.
This is totally not a UNIX question though
this helps a lot
?
Dunno, having python installed ootb is a convenient thing
Phew good thing I have BSD distros to fall back on. Linux โ BSD โ
Hey guys what's a serious good linux distro I can count on for many years for my future work ( I have a high-end good specs laptop) but I still want to know a good linux distro for work and one that will be nice to depend on . im currently using ubuntu and I have been seeing some people talk about linux mint too and other distros
These days, there are a lot of interesting ways to go if you want.
Including such approaches as https://blue-build.org/
I'd stick with ubuntu -- not because it's "the best" (whatever that might mean), but because it's clearly pretty good, and afaict it's the most popular. Popularity counts.
nah, what would that even mean? (even if i think i kind of understand what you are trying to say/ask)
ya it sounded weird ig but it felt like it kinda made sense too ๐
there is no real default distro, different distros have their different uses and target audiences
everything from Ubuntu, Fedora and Arch to NixOS or something very specialized like Qubes OS (which isn't really even a "normal" linux distro since it got the Xen hypervisor underneath the linux kernel instances)
yup agreed some people are used to 1 distro none other than it
Kubuntu faithfully serves me for years.
Reasons:
- Ubuntu is first supported everywhere, easy to find guides
- Easy to install everything, apt install smth, snap install smth, apt install ./some_deb, wget smth
- Docker images are often debian based as easy solution, Ubuntu is debian based => so i am familiar with the most commonly used linux distro by default, differences between Debian and Ubuntu are very hard to notice
- Also same Ubuntu/Debian pick is common way to go for servers too
- Kbuntu is Ubuntu flavour with KDE Plasma GUI, it is just very familiar/comfortable one for me, former Windows user. Task bar is correctly at the bottom, desktop with links, Supet good default terminal with multiplexing/multi windowing feature (the most important part for me). GUI just works okay on defaults for me
In general if u are not a person that wishes to have a lot of brainfuc.k with Linux... picking smth Ubuntu based is good idea
Whatever GUI u will like to it (be it vanilla Ubuntu, or Xubuntu, or Lubuntu, whatever. my choice is Kubuntu LTS)
LTS - long term supported version, important to pick for maximum stability
P.S. when i visited at some point office of my company, everyone was having installed Ubuntu by default ๐
we can say that about KDE Plasma flavoured distros yes in terms of interface, except underneath can be not only Ubuntu but smth else
I pick ubuntu though. the same GUI is pairable with any other linux distro
So u pick usually your "Distro underneath" (their amount is fairly much low of common known and long term supported), your "Gui", and from there possible also some extra more specialized choices
https://www.geekersdigest.com/updated-list-of-linux-distributions-with-long-term-support-lts/
Good idea for your Distro underneath your GUI picking only Long Term supported stuff only
====
Extra note. I am DevOps engineer and i am having Very Much enough brainfuc.k with configurating different tools (or coding some applications when i go for some Backend stuff)
Not going to build my own linux distro
I enjoy Kubuntu because it does just work out of the box and i don't need to configure anything extra in it (beyond running few apt/snap install commands and hooking my bash scripts for quick actions)
I enjoy Linux(Ubuntu) because it works the best for web development/server infrastructure tooling, everything is supported natively
some people prefer rolling distros, but i would say that is either for more adventurous linux users or seasoned linux users
and for stability some people want some kind of immutable distros where you can easily reboot and be back to previous versions of all your os managed software
and some like declarative distros where you can reinstall everything on a new system and be back mostly as you where as long as you have a backup of your own files
yep that's what I want just smth nice out of the box configured not alot of work that will be good for work
i also think ubuntu (or some flavor of it) will be right for you if you are already a little bit familiar with it and have no strong feelings against it thous far
I think I would js want smth stable and easy tbh
I also want smth stable so it won't cause problems with any type of work im trying to do
tbh ya ur right about that
my first experiences with linux was with kali
tbh took me some time to get used because I was still a newbie with commands and programming in general
but I got used to it
which is why I don't have any problems attempting to solve bugs or use the terminal or mess around in the OS
and which is also why im ineterested and open to check out many more options
kali is built on top of debian, just like ubuntu
ngl I learned a LOT long ago by doing a Linux From Scratch build.. I wouldn't do it twice, but if you're ever bored, I actually recommend it.
if i was embed dev, may be it would be fun for me.
Otherwise my learning schedule is full for a year ahead problem assigned.
- with grafana stack covering pet projects
- doing pet projects in go
- and i should dive into Java/Kotlin, and it will consume even more time ๐
While i am still young enough biogically in general, wishing to conquer all important languages at a deep level to be comfortable with them
very rewarding sort of, as each ecosystem/language unlocks to more possibilities what can be done (and more job stuff too hehe)
probably Java/Kotlin is the last important thing to conquer ๐ค
dotnet looks gradually more attractive though with being linux friendly and having some neat stuff in it. Seriously considering to add it to my plate, but i will be fine with just conquering JVM world may be too
The dotnet intermediate representation language is pretty cool/interesting.
Ubuntu is my favorite Linux distro
ok guys what do u think about manjaro?
I'm pretty skeptical of distros that are "we're based on Distro X, but we're more user-friendly!"
It's really hard to do that well, especially without falling behind the update schedule of what you're based on.
And why didn't they just contribute back to "Distro X" etc etc?
That being said Manjaro supports Xfce so they do get some points. Xfce is great.
well tbh I wanna get more into computers and I'm down for the experience of low level so what do u think?
Even from that perspective I think it's not ideal. Before Manjaro I'd suggest just trying Arch (its parent) directly.
If you're really down for the low-level I personally had a great time with https://www.linuxfromscratch.org/ but it's probably not what you want to run day-to-day, it's more about learning from the ground up.
mhm I see
That being said there are a lot of fun distros to try, and these days whole distro 'approaches' to try
Like with this, you have an 'immutable' base install of Linux, and everything you care about is a package on top of that that you can change out as you desire: https://blue-build.org/
A lot of people like this https://linuxmint.com/
I'm about to set up a machine with this to try it: https://garudalinux.org/
https://system76.com/pop/ also popular and has some interesting properties
doesn't this suffer from exactly what you were referring to about building upon another distro, since it's lagging behind ubuntu that it is based on quite a bit?
Yeah I wouldn't normally include it, but it has some nice things like making it easy to run the right version of CUDA if you need GPU integration.
So it's still on my radar despite being a derivative
but it's based on ubuntu 22.04 LTS, which is quite old by now and replaced by 24.04 LTS which is already through half its "better years" before getting replaced itself by the next LTS relese
Each Linux distro has custom frameworks. Even if they were based on an original. ๐ I know because I comb thru the stacks (directories)
Yeah, you're not wrong; I mean, I'm not using it myself.
and Garuda is marketing it self as
Your favorite Linux distribution providing opinionated settings that make the Arch Linux base easy to use
which is exactly what you didn't sound so keen on
I found this out because my student club is building a proprietary Debian based distro. Jk itโs just custom built
Yeah, it has a high bar to clear. I'm likely to do what I usually do and go right back to FreeBSD :V
Should my club market our Debian build
Millions and billions and trillions of dollars yes greed 
I am kidding by the way
that is really bad without ESM, but even with ESM probably not the best idea or practices
hahahahah
ESM and fairly airgapped do not fear
this is not a device i am running personally
for an old 3d printer or something?
or well, not one i am using as a desktop, it's a server at work that more or less has to exist and stay around, it's migration is on the task list for some time later this year
control system for a broadcast truck
that explains quite a bit
hahaha yeah
it just sits there and runs the interfaces to push signals through to a selection of PLC-type gubbins and hvac type stuff
@severe rain I've always been interested in Linux From Scratch and have wanted to build one for the longest. How was the build process for you? How long did it take and what was the Host distro you used when building it? What did you end up doing with the build? Did you customize it much? Still have the build and use it?
Great questions. Here's what I remember, as it's been a long long time:
- I remember the docs being surprisingly clear, I expected to have to do more side research than I did
- It was also surprisingly fast, but I had a lot of SunOS (Solaris) experience at the time so that helped. I'd give it a weekend.
- I used the build as a little in-house webserver for a while before replacing it with Arch.
- Amazingly I used Slackware as the host distro, which I can't recommend, but was still semi-poipular at the time.
- I customized a lot of the choices, yeah, e.g. the syslog system; it's fun being exposed to all the choices you could make there
- Sadly I installed (Arch?) over it so I don't have it, that would be amusing, since it used
initinstead ofsystemd
I'm trying to setup "hotplug" capabilities for a serial USB device to IO with a podman container. If I simply pass --device /dev/ttyUSB0:/dev/ttyUSB0:rw, I can communicate with the device. However when I remove the USB from my host and plug it back in, my container can no longer communicat.
Therefor, I am trying to setup a TCP proxy for this device such that in my Container I can listen for connections and in my host I can proxy through the connection. So now, my problem is described below:
I have a question for those familiar with socat and serial devices.
I have an embedded device I interface with over a serial connection, via character special (186/0) files.
I wanted to set up a virtual serial port "pipe" to this device with socat. However, I've noticed when I do that my physical device exhibits strange behavior (as if it might be pulled into reset? It should be blinking an LED but it is not when I set up this socat connection). Furthermore, I can't actually get my dev tools to communicate with it over this socat virtual piping.
Here's my host command:
socat -dd /dev/ttyUSB0,rawer,mode=777,user=(id -u),group=(id -g) TCP:localhost:12345
My container command:
socat -dd tcp-listn:12345 PTY,link=/dev/ttyVUSB0,mode=777,rawer,openpty
Then in the container I try to I/O with this /dev/ttyVUSB0
When I try to connect serially, I can see in the debug output that the connection is trying to write something. I believe the writing is happening from my tools side - trying to establish IO comms with the embedded serial device
There may be some TERMIOS options I need to set properly. So I followed up and found the man termios. I've tried everything at this point, I cannot get the device inside my container to behave like the underlying character device. I've used stty -F /dev/ttyUSB0 to try and match the termios flags inside the container, and that did not work (the flags did match)
I can simply obtain "hot plug" behavior by mounting the entirety of /dev inside the container. This is not my preference
Hm... Arch Hyprland btw or smh
Hello there
typically for grabbing something from a text file, is it better to use unix commands with the os module or default python io
or does it not matter
it depends on the complexity of the tasks. Some times just grep would do the work
I usually go for "default python io"
i use arch and the script i posted is in testing stages. I did not see that posting here was unix only. lol sorry about that. ๐
Linux has many ups an down but big down for Linux user is that it got wanna be Linux user and ragging comments on any social site / app without even thinking.
Does python community has these kind of people too?
What kind of raging comments a told about Linux, could u clarify? ๐ค
U mean that Linxu users promote it aggresively as it is the best thing
Or that other OS users think Linux is bad?
Ah. Yeah... typical behavour on Stack Overflow. Stack overflow is infamously famous for its bad attitude in general
And Linux users are known for being fanatically happy about their OS choice (i am Linux user too, hehe)
Join those things together and u will get answer like that
In general Linux users are just fanatically happy about it though. Agressive behaviour like that is more StackOverflow fault, as it brings the worst out of humanity for some reason.
i did not see Superiority attitude in python community i think. I often told to people currently in university to be better investing in serious languages like Java/Golang
And recounted all the disadvantages python has. (Like bad CPU performance (20 time slower than other languages), lack of real multithreading due to GIL lock, lack of typing making difficult code maintanance and refactors and readability)
Rarely i got any conflicts back. Quite python community cozy and relaxed
I always told some advantages of python too though, that it is quite easy to unit test language due to everything mockable at runtime and nothing being private, and easy to start with
Glad to hear that!
btw, as fanatical another Linux user i keep opinion that...
..Linux is best OS if u develop for Web development (Backend Development specifically) and as default OS for devs, and especially in DevOps engineering. Because last 10 years development of web happens only for deployment to Linux servers. It is just easier to develop from Linux for Linux ๐
I think that for University students better to run Windows with WSL2 having linux though. More stuff they will be able to run and university expects often to run some Windows stuff anyway.
Plus Windows has advantage of more games to run. For regular user makes sense to still use Windows just because it has more games easier to run -_- but Linux SteamOS stuff catchs up nicely and gaming on linux sky rockets to be more available
I don't understand only people using MacOS. worse for development than Linux, worse for gaming than Windows. and 2-3 times more expensive. I think MacOs people are brainwashed by Apple marketing to buy smth that is worse than other OS in any capacity.
The only thing where MacOS is better than others... it is to develop for MacOs. and that's because it is ridiculously proprietary system that makes things difficult on purpose
I have no grudge against Linux User.
I like them and Linux but some time I face such a fellow.
Internet is weird place to be in but I get agitated.
I'm learning to move forward and learn more but I hope so if there are folks reading me and did the same, I hope they won't in future (Just be happy and calm) .
I vaguely resent Linux for its willingness to support things that lock you into it vs. UNIX standards, but I guess in general I manage to keep that under wraps.
dude/lady... such people exist everywhere. It's not about Linux users or developers using a certain language. It's usually the people with the preachy attitude.
Someone would learn a new thing and they think that thing is the best thing since the slice bread and everyone should use it. Think, if you have a hammer everything looks like a nail.
I think in some ways it's the Dunning-Kruger effect too. But mostly it's about personalities rather than 'X' users.
i open #unix channel of the Python discord and the discussion is about Unix users.. never change, developers ๐
I wouldn't say MacOS is worse than it's alternatives, but rather it just depends on your needs. For someone like me who doesn't really play video games anymore, there's very little benefit to owning a Windows machine (not to mention all the bloatware and spyware). Linux seems great, but it just doesn't have all the software I need. I own both a PC and MacBook, and I just generally prefer MacOS, especially because of how it plays nicely with my other Apple devices.
At the end of the day though... use whatever you want no one cares lol
where do i get amazing apis not the generic stuff like dog image api i mean useful apis?
Like web APIs? https://github.com/public-apis/public-apis
What would make a useful api for you?
i need unique apis to impress employers like something for knowing the best fruits to plant for a specific type of soil and know where to plant it
i bet you can find geodata on soil and weather conditions and aggregate it for user's GPS location
yes you can
i have a .deb file coded in py i need a .app file for a macbook
what to you mean?
you want to make a mac executable out of the python script?
in that case i think you need a mac first to be able to create that executable on
ok i dont have a mac ๐ฆ i was going to do this so that my app could be on mac. then i was going to make a windows one. i do have win 10 installed but idk how to make a exe file or whatever i gota do.
there are several ways to make an executable, one of the most common ones is by using PyInstaller on the platform that you want to make an executable for
cross compilation is somewhat possible but not realistically for mac or iOS/iPadOS and such due to Apples policies/EULA/ToS where they require you to compile things for their platforms from on one of their platforms, so it's all down to Apples restrictions on their products
in other words, they require you to get a mac or in some way get access to a mac to be able to create the application binaries for mac or any of their other platforms
Ok
Thank you
@wise forge help me to get on with Linux (like give me some tips)... I'm a newbie btw ๐ฅฒ
@gilded surge share the image here
If Linux is not Unix then why did they name Linux after Unix
abc
random for that unix linux thing you said
because i couldn't answer
That works. An eloquent conjecture. Abc. Enough said
Whats sad is that people actually do care
Linus named it after himself
What does mean something?
(something)
double underscore something double underscore
System defined names https://docs.python.org/3/reference/lexical_analysis.html#reserved-classes-of-identifiers
Hello I am having trouble running anaconda-navigator from my rofi drun menu.
I ran rofi -show -drun from my zsh and my anaconda-navigator works fine
but when i super + d and select anaconda-navigator nothing happens
this is my desktop entry for anaconda-navigator on /home/aadithya/.local/share/applications/anaconda-navigator.desktop
[Desktop Entry]
Name=Anaconda Navigator
Comment=Launch Anaconda Navigator
Exec=zsh -l -c "source ~/anaconda3/etc/profile.d/conda.sh && /home/aadithya/anaconda3/bin/anaconda-navigator"
Icon=anaconda
Terminal=false
Type=Application
Categories=Development;
I was trying to learn ML in python so i thought this server might be ok to ask i am sorry if this is not the right server
Oh man, maybe I should at least try this... https://github.com/helloSystem/hello
What do you call a process that just doesn't exist? Like for example, you lookup a process and it is a zombie, and zombies are dead for various intents and purposes, but what if you want to lookup a process to verify that it is completely dead like not a zombie, just doesn't exist due to being killed + reaped and all that jazz.
๐ค
I think I'd call it "a process that no longer exists"
what problem are you trying to solve?
I'm working on code to start a process, use a wrapper, set the parent death signal, and testing that when the parent dies abruptly, the child will die. I started writing functions like verify_process_is_alive(pid) -> bool and verify_process_is_dead(pid) -> bool (for more general use than this problem too) but then I wasn't sure of the design or what should be considered dead or alive because a Zombie process isn't entirely a dead one, and I was going to check if it's alive by if the process existed in /proc/. Process that no longer exists is what I'm thinking of at the moment and just differentiating for functions between if it can be looked up, vs if it is a zombie or something.
I assume you have exactly three possibilities:
- it doesn't exist at all
- it exists, but is a zombie
- it exists, and is not a zombie
I'd have thought there'd be one or two simple libc functions that, given a PID, would tell you which state it was in ... but I don't see any such thing. I guess it's specific to the Linux kernel, and I don't know its API, nor how to interact with that API from Python
Unfortunately the libc functions are lacking for some of this stuff but everything is available through the filesystem at least which I have covered, i.e.: It's just that I'm designing this and trying to account for multiple platforms for testing to see if a process has died, but "dead" doesn't totally mean dead in the way I'd thought it would when a Zombie process still technically exists in the kernel, and on top of that can still be looked up because it'll exist at /proc/{pid} still just with the stat file having a Z in the column. But yea, I think it's just 1) non-existent (not alive, not a zombie), or on windows just can't be looked up at all I think and not as interesting (speculating here) 2) it's alive (it exists and is not a zombie) and 3) it exists and is dead (like zombies are). So I think you're right and I'll just focus on weather or not it exists or not for what I care about and differentiate between existent or zombie where relevant.
# FIXME work out a design for this/differentiating between it being dead or alive
def verify_process_is_zombie(process_id: int) -> bool:
"""
Verifies that a process with the given id exists and is a zombie. If it can't be
determined if the process is a Zombie on the platform, then False will be returned.
"""
if sys.platform != "linux":
raise RuntimeError(b"platform {sys.platform} not supported")
try:
with open(f"/proc/{process_id}/stat", "r") as f:
line = f.readline().rstrip("\r\n")
# if the value of the third column is Z then it is a zombie
indicator_on_third_column = line.split()[2]
return indicator_on_third_column == "Z"
except FileNotFoundError:
return False```
That's pretty much how I'd do it
pretty sure you won't find carriage-returns in files under /proc ๐
Woops. You're right. I am just used to writing both and typed that by habit. ๐
It does have to work on multiple platforms but not all of it. It only has to if it has zombie processes in a meaningful capacity. Like if I look up a process on Linux it could be a zombie and not entirely dead (non existent) like I'd want it to be after. But on windows even though there is stuff that can go wrong that leaves stuff in a zombie like state in the kernel (if I read correctly) once it can't be looked up that's about as much as seems like should be cared about. At this point I am just gonna verify explicitly that it doesn't exist, or if testing for a specific platform and debugging further checking if it is a zombie or something.
I'm working on code to start a process, use a wrapper, set the parent death signal, and testing that when the parent dies abruptly, the child will die.
It sounds like you wouldn't need to recognize zombie processes at all for this. You start a child process, then a grandchild process, then register that the grandchild process should die when the child process dies, then kill the child process, wait a bit, and make sure that the grandchild process is now dead as well, by checking that you can reap it
that is, you call os.waitpid with the grandchild's pid and the WNOHANG option, and you should be notified that the grandchild has died
once the child process has died, the responsibility for reaping the grandchild process bubbles up to its grand parent process, unless you've started a new session group at some point (in which case it falls to pid 1)
I'm doing all of this at the moment minus the last partYou start a child process, then a grandchild process, then register that the grandchild process should die when the child process dies, then kill the child process, wait a bit, and make sure that the grandchild process is now dead as well but my issue was checking if it is dead and I wanted to do it in more of a blackbox fashion kind of where I'd look it up on the system and verify that it is truly dead, as in doesn't exist anymore through that. Aside from the definition of dead vs non-existent initially I've got it working and am doing in my test essentially as follows. 1 -> starting the child from the grand parent. 2 -> the child is starting the grand child and then sleeping forever. 3 -> the grand parent is giving it a sleep of one second so that everything has time to start up and so that the parent death signal will be sent ||(I'll consider improving the design to allow the wrapper script to give a proper indicator that can be found on the filesystem or something later)|| 4 -> sending SIGKILL to the parent process. 5 -> waiting for it to be dead 5.1 -> Actively waiting for it because sending the signal doesn't result in it dying right away, so giving a bit with a timeout. And right now I'm not reaping anything and it results in the process not existing at all and not just being a zombie.
def test_should_have_end_result_of_child_script_dying_when_parent_dies_abruptly(self):
# A script should be able to use GracefulProcess to start a process
# and when that script is dead and unable to tell it to shut down,
# it should be killed automatically and be graceful. The implementation
# of this functionality for Linux can be to make the child set the parent death signal.
#
# And the above can be achieved through a wrapper script which does it before execl. This test
# is not focused on implementation detail, but context is somewhat necessary to get the premise.
start_command = _get_python_script_start_command("child_parent_graceful/parent.py", [])
raw_subprocess = subprocess.Popen(start_command, stdout=subprocess.PIPE, stderr=subprocess.PIPE)
time.sleep(1) # -> removing this sleep I think results in the parent death signal not being set
# ^ We're subprocess directly because inside it's where we have a graceful process that does the whole shebang.
parent_process_pid = int(raw_subprocess.stdout.readline().decode().split(":")[1])
child_process_pid = int(raw_subprocess.stdout.readline().decode().split(":")[1])
os.kill(parent_process_pid, signal.SIGKILL)
# raw_subprocess.wait()
# raw_subprocess.kill()
# self.waitForProcessToNotExist(parent_process_pid, 10, f"process {parent_process_pid} did not die in time")
self.waitForProcessToNotExist(child_process_pid, 10, f"process {child_process_pid} did not die in time.")```
If you can reap it, it's definitely dead. If you can't reap it, either it is still alive, or someone else has already reaped it. If you did not start a new session group, no one else could have possibly reaped it.
Unless the grandchild died before the child, I guess (in which case the child could have reaped the grandchild)
If I set the parent death signal on the the grand child and the child (it's parent) dies abruptly, then it doesn't become a Zombie or anything like that and wasn't what I was concerned about. I'm just building up a decent amount of stuff along side of this and trying to get the definition of dead, alive, non-existent correct and for using it here. e.g.
import os
import sys
import time
sys.path.append("../../../../")
from pathlib import Path
from <redacted>.processes.normal import GracefulProcess
print(f"parent-pid:{os.getpid()}", flush=True)
process = GracefulProcess([sys.executable, Path(__file__).parent / "child.py"])
# I think in our test cases by the time we kill it, it hasn't set the parent death signal in the child script
# assert process.get_line_output_reader() == "parent_death_signal_set"
process.start()
print(f"child-pid:{process.pid}")
while True:
time.sleep(0.1)```
child.py
```py
import time
# print(f"child-pid:{os.getpid()}", flush=True)
while True:
time.sleep(0.1)```
If I set the parent death signal on the the grand child and the child (it's parent) dies abruptly, then it doesn't become a Zombie or anything like that and wasn't what I was concerned about.
Huh? It absolutely should. A zombie is just a process that has died and that has not been reaped. The parent process is responsible for reaping it, but if that parent is dead, the grandparent is (and so on, up the chain), until you reach a living process or a process in a different session group (in which case it falls back to init, pid 1)
If your grandparent and grandchild are in the same session group (you haven't called setsid), then the grandparent should be the one that needs to reap the grandchild, and the grandchild should be a zombie until the grandparent does
Ooh, no, apparently I'm wrong: the orphaned process isn't reparented to the grandparent, it's always reparented to init, unless the grandparent has called prctl with PR_SET_CHILD_SUBREAPER
That makes it even easier, though, tbh - as long as you have a functioning init process the child will never be a zombie for more than a few microseconds
||(I've retracted my entire previous statement to not spam the channel and to make my response more concise)||. Yea, I was able to reproduce this in an isolated experiment where I did it all raw basically and spent hours (on various days) debugging this and wondering why my test would pass when I changed stuff slightly but not other times. In regards to a functioning init process (not so educated on it) but in my tests it has never reported as being a zombie, just existing and alive, or non-existing and completely dead so I think the time is definitely too small to matter and I'm prepared to actively wait for it with a timeout at this point as that's what I'm expecting the end result to be. So my problems were race conditions. I'm attach the files for context for reproducing all of it.
Click here to see this code in our pastebin.
Hi! I have a very curious problem: I would like to manually activate a venv (without using source .venv/bin/activate, I need that for my vimspector debugpy config). My test venv has a module that I do not have installed globally. Looking at the activate script, I cannot see it doing anything other then (i) setting VIRTUAL_ENV, (ii) setting PATH, (iii) unsetting PYTHONHOME, and (iv) defining a deactivate function. However, if I set those 3 environment variables manually and run my python script, it complains that the module from the venv was not found. But if I activate the venv via source .venv/bin/activate and then run my python script, it works. So there is some magic happening that I cannot find ๐ฆ I have even diffed the output of env | sort in the activated environment and in my manually recreated environment, and except for the OLD... variables, there is no difference. Does anyone know what I am missing?
Does anyone know what I am missing?
just use path_to_venv/.venv/bin/python3 as executor
u don't need to activate venv then
Unfortunately, that doesn't work either, it still complains that the module cannot be found
๐ค change Working directory towards your Project folder
and set if necessary PYTHONPATH to same location as project folder
(should be caused by prepending the venv path to $PATH anyways, but I also tried directly running python with the entire global path and I got the same effect)
Same problem ๐ฆ
Wait, sorry, I must have broken the venv somewhere along the way, now I cannot repro getting it to work in the venv.
Venv is forbidden to be moved from the folder where it was created
changes to Abs path break it
Sorry, it seems I need to debug myself a bit more - this is a venv I created using nix develop, and depending on how I activate it, it works or doesn't work. Seems more like some dark nixOS magic that I need to figure out than a venv problem.
You need to not just create the venv with nix develop I believe, but to be in the nix develop shell also every time you run it. That's my recollection of the nix story at least, it's been a while.
Thats a lot of long messages ๐ญ๐ญ๐ซก๐ซก
(Unreleated to python) Anybody here knows dwm's desktop environment?? Especially on Debian's -- I just want to know how do you start it after you've finished edited some things in .xsession (or .xinitrc) file?
No, it sounds cool though
Is it the one that u have to recompile every time?
I used it a decade ago. yep. reconfigure by recompiling
Hey guys anyone use qubes OS?
Its ok
I dont need it nd honestly tails on a portable stick is more secure if thats the main concern
Noted. Im kind of new to this i want to know where i can learn pentesting? I want to excel in my career.
i would start with kali linux, it's just the standard and is really easy to get started with
there is also parrot os, which is from hackthebox.com a good website, it's just locked behind a paywall
tryhackme.com is my fav, personally
I appreciate you man, means a ton, can I add you on here?
Unix is a kernel of Linux, correct?
What is Unix good for aside from being user-friendly?
Unix is prehistoric inspiration for Linux
In its honor the channel is named Unix, but practically it should have been Linux
Great for anything related web, backend, DevOps development.
Native docker run.
Natively running all web dev
stuff
Ability to multiply your ram with zram ๐
Dev friendly OS with responsive detailed errors if smth goes wrong. If u are able eventually appreciate its style, u get used to its way and unable to pick anything else any longer
Performance efficient to your hardware, runs mostly anywhere
Does not contain annoying malware avg windows has, no AI, no windows updates, no security beaches with recall and etc. Linux is made to be used by real people instead of promoting greedy corp interests and annoying features
I did not know that Unix was older than Linux. That is pretty cool to learn.
What does DevOps mean and what does it do? What is a Docker Run?
Iโm sorry if these are silly questions to ask. I am brand new to computer science as a whole. All that I am familiar with is that there is three main Operating systems (iOS, Linux, Windows), a couple of programming language names, that RAM and SSD mean two different things, and that you can reroute the function of certain hardware through the software. That is all that I am familiar with right now. But I am genuinely interested in expanding my knowledge so that I can be a great software developer.
DevOps has different meanings, but practical one would be saying using Infrastructure as a code tools for programmatic management of server infrastructure. For usually running of backend applications but not only that
Modern web/cloud solutions have quite sophisticated setups to run well in high availability, horizontal auto scaling performant and monitor able and etc stuff. Special tools/languages simplify it considerably
Docker is a thing... In web development that became a standard for last ten years as better alternative to virtual machines for running applications. Or instead of running them in polluting main os directly with their dependencies
Instead of creating entire VMs, we now wrap all web apps to lightweight containers, that embed infrastructure as a code approach to build them, they reuse existing Linux kernel/core for their lightweight running, and run with uniform way for deployment.
If u learn to use docker, u will be able raising any db in 30 seconds
Including raising things like even entire complex apps as long as they have docker compose to them written
Docker is standard to wrap and run anything web app related and became having rich community-ecosystem of ready to use solutions
So Linux is really good at cloud computing because it is excellent for DevOps development?
yes.
It's the opposite of user-friendly, though.
Many of us nerds like it; but for normal humans, it's awful.
Such as lack of keyboard controls?
such as very little decent work done on user interfaces
User interfaces are hard, and unpleasant to develop; and the only people who do them well are professionals who get paid a lot of money. Totally free software cannot afford to pay their salaries, so they go work for Apple or Microsoft.
This is a controversial opinion.
You might as well download a Linux distro and play with it; it's free (if your time has no value ๐คฃ)
I recommend Ubuntu
Vim is what I think of when I hear keyboard controls. Linux UI are by developers for developers, for better or worse
What is vim? Virtual Machine?
What do you mean by โdecent workโ? Are most Linux kernels unfinished and unusable without much work put in? I understand that some kernels do not have user interfaces like Windows and iOS does, but what I am curious about is how some systems donโt have keyboard controls? I understand not having mouse controls, but keyboard? How are you able to input commands without a keyboard?
I can understand that programmers donโt need user-interfaces because all that matters is the ability to look at the code itself and make changes. None of which requires a user-interface to function.
I hope that I can get to a point where I can have the knowledge to code without using a user-interface. I think that would be quite fun to do.
I was talking about user interfaces, not kernels. The kernel is world-class.
Oh ok. My bad.
Yes, also because only Linux is used for modern web development deployments to servers.
Web apps run at Linux Servers
@gilded heath it is Dev-user friendly and very easy to solve its problems assuming u a using popular distro like Ubuntu/Kubuntu
That some people find it not user friendly, araises only from people having freedom to do everything and they try to do everything (arch users), and attempts to launch windows only software at it, or being in general not used to it non tech users unable to read
Modern Linux does have graphical user interfaces. Just install Desktop version of Kubuntu for example
Kubuntu is most close looking to Windows and easy to use, makes nice transition
Linux users understand importance of user interfaces and they are all present
But there is crucial still difference in...
Linux philosophy to program installation and configuration majorly using Terminal/Console for that.
It is addictively comfortable choice to see detailed logs and responses when doing that, very dev friendly, very Power User friendly. OS is not hiding stuff away from you.
After u get used to it, u see Windows interface as User Not Friendly. How the heck to work with OS where any program installation and its usage IS NOT telling why it is not working?
After using LInux i feel pretty much crippled in how much Windows is NOT POWER USER friendly
all Windows focus always aimed to be friendly for DUMB NON TECH user. And pushing for whatever corporate shit they wish at the moment in addition.
At the end of a day Windows is not even aiming to be friendly for Dumb Non Tech user as first priority, they push to make cosmetic changes to their interface for the sake of justifying to sell more copies/licenses of it
Why else they would be rehiding Settings/startup and other stuff each time again and again ๐
Why else they would be making sure user does not have rights to administrate its own OS, and denying access to service changes, to windows updates
Why else they would be making harder to create local user and pushing for their cloud user nonsense
https://youtu.be/2zpCOYkdvTQ
if u will start using Linux and get used to it, u will discover what is OS that is actually made Friendly with (Power) User in Mind.
sure -- when I say "not user friendly", I mean your grandma won't want to use it. Developers generally prefer it.
But you know -- I'm a developer, and I like (most of) the grandma-friendly stuff too.
to be fair at Gradma level, Windows is equally confusing thing
or at least all my grand parents rarely figured out stuff
if they are IT, then their inability to use Linux, only because of different made choices when living in IT ^_^
Linux very grows on you and u become very attached to its structure and logic at some point
well I know that. But I'm a long-time programmer
Also with Windows strategy to rehide interface and confuse the user...
...any thing they learned about Windows probably got already too much outdated ๐
Would Mint also be a good kernel to use?
Should I learn how to use terminal before I install Linux or afterwards? Does Windows prevent people from using the terminal console effectively?
I want to become a smart tech user, which is why I want to use Linux for the reasons that you have provided.
Mint is Distro. like all inuxes it uses same Linux kernel as others.
It is Ubuntu based, so it should be okay easy enough to use
Should I learn how to use terminal before I install Linux or afterwards?
it would be a good idea to get small grasp at least eventually, during, before or after installation.
Does Windows prevent people from using the terminal console effectively?
Windows is essentially not automtable beyond some crude measures. Windows is made with GUI first in mind.
Linux is made with terminal/console first in mind.
Linux has grown ecosystem around it to automate it, from professional way to hobbiest ways different tools.
Any automation u will find for Windows are only crutches to work around to bring some level of it, but it willl never be even close to Linux in terms of automation.
Linux will remain dominating in terms of being automations to be configured as desktop and server machine just because people invest only into it, because linux has Free licenses and can be spawned in whatever amount it is necessary for it, and windows is not free.
Modern web infrastructure requires dozens/hundreds of server machines being spawned in autoscaling
Windows has High overhead due to a lot of trash running in background besides lack of automations, it is just too much more expensive, so the obvious domination of Linux in server web infra happens already last dozen of years at least
Some Windows administratrators try to automate windows anyway, but they deserve only a lot of pity for their sufferings
I had a feeling that Microsoft Windows is hiding a lot of important things behind its โbells and whistlesโ. I have already noticed that it is a hassle to access important functions on Windows, and recently I have noticed that they removed certain features like the ability to change the clock from 12-hour intervals to 24-hour intervals. It severely pissed me off as I very much prefer to have the clock set with the 24 hours option than the 12 hours that is the default on Windows.
Ok cool. I will get on it right away.
Linux is great to use if u wish to be developer at least. ^_^ At least if u don't plan to be Windows Desktop or Macos destop dev.
Linux devs can work around and develop windows apps even from linux but it could be a be more difficult thing highly depending on the used language
if u develop For Windows, u still have to launch it from time to time at least in VM
i have rarely needs to launch Windows though as i am web backend dev / devops engineer / just picking games friendly for linux
i launch Windows only like... 1 time per year ๐ usually regretting doing that and turning it off back
Anyway, using Linux u will benefit right away at least just by saving a bit of money on licenses, and needing less hardware to run it
Beware, Linux does not work well for Windows only games, but it can work okay as long as u choose Linux friendly games
https://store.steampowered.com/linux
17673 games in Steam at least natively support Linux
i plan on my current weekends to raise Minecraft modded server for example ๐ works well too.
More than that, Minecraft-Java tech is friendly for launch on Extra Cheap arm64 Linux servers from hetzner
Enjoyed to play Starsector in previous vacation
Great games usually support Linux, if they don't support it, they are usually not that good in the first place ๐
Yeah no, I am not looking to be a Windows or MacOS developer. I want the ability to be able to modify my computer however I see fit, and working with Microsoft or Apple software wonโt allow me to have that ability. So I am good with sticking to Linux.
it is quite enjoyable using OS made actually indeed For User.
running stably same installation for years ^_^
Anything dev related is easier to acomplish at Linux, since good devs obviously support Linux first for dev stuff. (with exception of specified exceptions)
I am ok with losing the ability to play Windows only games as long as I have the freedom to decide how I can use my software however I see fit.
too much game playing is bad thing to do anyway.
and amount of games supporting Linux is too big for one person to play for many lifetimes anyway already too ๐
Steam does really good stuff in promoting Linux gaming
It would be nice if one day it entirely dominated landscape, then the last major point for Windows usage at Desktop will fall
https://en.wikipedia.org/wiki/List_of_Linux_adopters#Education
Plenty of countries adopt Linux right away across all the machines anyway at least in Government and Educational/Schools sector, if only they can have less dependency on USA proprietary software
I would love that too. I absolutely hate how Microsoft owns a big monopoly on software to the point of forcing people to use Windows for everything. I want complete access to my computer, alright? Not have it controlled by Microsoft or Apple who only seeks to push me to buy more of their products with even less features than their previous products.
Oh cool! That is what I like to see.
@wise forge May I ask what you do as a DevOps person? Do you make certain mobile apps or something?
DevOps engineers operate with server infrastructure as a code usually.
-
Company has dozens of backend server applications to run. Who has written infra code to have them running? DevOps engineers by using Infrastructure as a Code tools (Docker, Terraform, Pulumi, Kubernetes, providers like AWS, GCP, Azure and etc)
-
Company has dozens of backend, frontend web apps. and devs wish to write features only and not being distratected by how it is automaticlaly tested, built, released and deployed? Devops engineers using Docker, AWS cli tools, Github Actions, and different other scripting glue if necessary. Devs just marge to master branch, and the rest by their code automatically gets deployed to staging.
-
Company has dozens of backend, frontend applications, and even mobile ones. Who gives help to raise centralized distributed monitoring systems to monitor their performance if they behave correctly in production? Devops engineers using Grafana/Loki/Tempo/Mimir-Prometheus, or Sentry, or Datadog and etc tech, deployed through Terraform/Kubernetes/Docker whatever means
-
Company has bad performance on frontends, too much high traffic, needing caching. Who will fix it? Again devops enginers will configure CDN from cloudflare/bunny/aws whatever
-
Devops engineers will automate deployment of web applications
-
Devops engineers will automate tracking health and performance of applications
-
Devops engineers will seek optimizations to spend less money onto all this infrastructure to run this stuff
I was originally just Web Backend Developer that had responsibilities to deploy backend/frontend on my own with whatever means ๐
I wished to automate stuff, and not keep in my head how the things are done regarding productional running, so eventually learned plenty of tech for that
There are Devops engineering roles with more focus onto Operational routine to handle just raised problems, and they could be handling baremetal servers too. Such people are usually called Site Responsibility Engineers, but i have more focus onto being Dev first DevOps engineer and have aim onto just making software development easier for devs
Cool!
A good first step towards devops stuff, learning how to wield docker containers well. That will be useful skill for backend devs/fool stuck devs too
And learning at least just how to write CI for their stuff at repo
Docker alone helps u having more flexible dev env, fully emcompassing all dependencies it has.
That is usually still responsibility of backend devs to learn though
What is the difference between DevOps and Networking?
I was recommended Networking because some of my interests lie in that field
devops engineers can be needing networking, but i think it is pretty minor and just basics stuff. ๐คทโโ๏ธ
at most biggest networking devops engineers do... configuring Public/Private networking separation for the soft to run. it is not a big problem too and thing that can be done with small amount of tries and errors.
fully fledged Networking job roles usually assume you are network designer / advanced form of system administrator that is able to set networks and servers in a physical world.
Devops engineers usually do not interact with physical world and configure it at the level of infra code provider automating tools.
Unless the devops engnieer is more site reliability engineer, sys admin on steroids more focused on operational duties, in which case he can be having network profficiencies too, to operate correctly hardware.
Depends on the specific role and how company understandards them.
Some DevOps job roles never deal with physical servers
Some Devops job roles deal a lot with physical servers and networks. only the latter ones need deeper networking knowledge
Both job roles by accident are named with same name of a Devops engineer, despite very opposite duties.
DevOps sound more interesting than Networking does. Mainly because I love the idea of automation.
How should I start learning how to be a DevOps developer?
Would you say this falls align more with DevOps or Networking?
โBecause the reason why I want to become literate when it comes to technology. I want to have more control over my technology, more control over my data, avoid malware and predatory services, and stick it against big corporations that holds a monopoly on everything we have in life. Iโm just fed up with the direction the world is going right now, and I am even more pissed off with how the big software companies are controlling our digital lives.โ
I really want more control over my data and what I can do with the technology at hand. Whether it is automation or something else.
i would say it is atitude of regular person wishing to have more FOSS/Self hosting in his life
Here is a tutorial of a person that went ultimately crazy about it ๐
https://wiki.futo.org/index.php/Introduction_to_a_Self_Managed_Life:_a_13_hour_%26_28_minute_presentation_by_FUTO_software
I prefer to stick to balanced pragmatic level of it.
- i make sure my server infrastructure is using self hosting means if i can, for homelab at least
- i make sure i manage my backups on my own, and make sure i will not get locked out of accesses because of ridiciulous corporate decisions
- i like to manage my own site
- and i of course enjoy using linux as OS, as it is more fitting my dev needs and just tastes in general at this point
otherwise i will not be bothering ever with managing my router software, or email, not going to do anything related to phone too, those are all difficult challenges, or not worthy of my time challenges. I am happy to pay money to my Internet service provider and having things running in this direction
although i did actually rather.. big thing of relocating to another country where internet is way better and not censored
my origin country went a bit crazy with censoring everything
What country did you originally came from and which country do you now reside in?
i probably at some point will make dedicated Network accessable storage/servers to store my files though may be. that could be a good thing to have
i am very happy with keeping my passwords and otp keys in https://www.passwordstore.org/
Which i backup to several git accounts with git-crypt solution
Pass is the standard unix password manager, a lightweight password manager that uses GPG and Git for Linux, BSD, and Mac OS X.
i am now not at risk to have all my accesses lost if anything happens to my google acc
So... i do self hosting my life in reasonable amounts, the ones which are easy to implement/maintain/free to maintain
I want to reach a practical level of development in my IT development too. I just donโt know where to start as there are many different directions to go onto.
i lived in Russia, i chose to live in Serbia
I want to get to that level too eventually.
How should I start learning how to be a DevOps developer?
learn to be Backend developer first, build backend apis, web sites,
Learn smth like building things with Golang, .Net, or Java Quarkus stuff
Master being backend dev, learn working with relational databases properly and building things in quality in general
https://darklab8.github.io/blog/favourite.html#UnitTestingPrinciplesPracticesandPatterns
https://darklab8.github.io/blog/favourite.html#TestDrivenDevelopmentByExample
https://darklab8.github.io/blog/favourite.html#CodeCompleteAPracticalHandbookofSoftwareConstruction
Build stuff with quality
Learn backend dev fluff https://roadmap.sh/backend
learn to own infrastructure more with learning how to use docker (read book about it too, like Docker up and running)
Progress eventually to automate all server infra (Terraform up and running is good step forward)
Explore stuff devops engineers use https://roadmap.sh/devops
alternative path assumes being sys admin more somehow first, i have no idea how the path goes from this.
I went to devops from being backend dev, and i help backend devs with infrastructure/automations/observability for their apps
Oh cool! I was raised in and still currently reside in the US. With how things are going along right now I figured it was high time to learn how to develop software and become computer literate. That and also because it fits the skill set that I currently have as well as desire.
Would it be advisable to stick with Windows for right now or just jump straight into Linux? Because I really want to install Linux right now, and I am ok with taking risks if that means that I am forced to learn on the spot. Especially since I learn best by simply doing the task in front of me.
I can do that! Thanks for giving me the advice! I will go for that right away.
i think it is great to go for Linux right away. less to relearn after that
It is best to do IT career with getting CS degree first though, and in university u can be asked to run Windows specific stuff
there can be a point to use Windows with WSL2 during your university education for those reasons, or at least keeping Windows at dual boot in case of emergenecy
if keeping Windows at dual boot, i think there is nothing holding to go for Linux as primary OS
Oh? I thought that it is perfectly reasonable to learn how to code without getting a CS degree? Especially since I heard that CS college education does not teach you how to code that much. At least where I came from. Am I wrong on this assessment?
Ask in #career-advice , there should be plenty of people from USA too.
As far as I am aware with CS degree u just have good avg chances to make the career in IT.
4 years help a lot to train your skills.
With some self studies on top and if possible internship, career has quite high chances to go
On another hand Plenty of companies filter people away if they don't have higher education in STEM by default for dev jobs.
It is possible to do without degree, but just way less likely by 10 times.
Harder to get career perspective positions
U will need somehow shine despite this big hole in your resume. Having good enough luck or relatives in necessary positions, having very good portfolio or plenty of experience in some lower ranked positions
Alright. Thank you for letting me know about this. I will keep that in mind when I get farther along my journey.
hi just have a question, i get some weird things on RPI4 after some time and reboots the SD card looses its partition table i guess i get this error
did anyone experience smthng like that maybe before and has a solution? when i format the sdcard and burn the image again it works again
doesnt the rpi4 want a fat32 sd card? and it says fat
idk tbh'
I have no experience with RPI casue i just make my own version of it i use to use them back when i was just learning python though there good frameworks to build your own software off of
well the thing was it was fat32 i booted the os it worked for a week and after that it did not boot anymore got this message
is it possible to make a bootloader as if it's just a program, but instead of loading an operating system, I mean for example make it like a program that adds two numbers? And the second thing is, does the BIOS put the interrupt table with it in RAM, which is the IVT, and put it at a specific address in RAM and put the value of this address in a register inside the processor which is the IDTR? And if for example in the case that the program did int 0x10, it would go for example to a specific address in the BIOS ROM and execute display code on the screen for example? Is this correct or wrong?
hAC
Has anyone come across a tool that can automatically identify configurations to be enabled/disabled for a given function to be comliled into the linux kernel?
I don't know anything about compiling Linux, so maybe the question already makes sense. But could you be more concrete?
When you compile the kernel, there are these configurations that u can tweak, each configuration enabled or disabled conditionally compiles in code from various modules (guarded by #ifdefs). Now, problem is these configs enabled specific modules (one or more kernel source files) for compilation. I want more fine grained control, ie, given a function name, i want to identify all configs need to be enabled/disabled along with conflict resolution (certain configs may conflict with certain other conflicts)
Github Actions written CI for every commit in git repository
And depending on present unit tests and turned on configurations, passing pipeline or failing it?
Assuming that kernel/unit test is smart enough to Panic/Crash/(preferably with Traceback) if u try to invoke not enabled stuff, it should work perfectly and be proper GitOps to the management of this thing
TLDR: regular git centric dev env
for unit testing writing to refer to popular unit testing framework/organization of a chosen language for which this thing is intended ๐
what does this have anything to do with the original question?
have you checked the size and complexity of the linux kenrel source which is also implemented using multiple programming languages (even if most of it is C)?
I am sorry I did not understand what you are trying to imply
even I was wondering the same
i implied that, instead of relying onto some tool to identify all stuff turned on correctly
could u rely onto CI workflow to run for Git Repository where configurations are done
To compile and unit test result as working as intended.
Can u just validate that features turned on correctly?
I make assumption here that linux kernel source is indeed large and has always changing documentation.
With organization stuff through GitOps with unit tests first, may be u will have at least some level of reliability instead of the approach u wish to do
your original question assumed relying onto the tool if everything was identified and turned on correctly
i encourage to see if it is possible to organize Git centric, Unit testing centric approach instead.
My line of thinking araised from: if u compile smth and call functions from it, then it should be automated buildable and validatable process?
Git first s friendly approach for system level dependencies configurations regarding infrastructure configurations
so could be the same approach used here, instead of attempting resolving it with third party tool?
if you have the idea how to make linter u make as reliable, it is good too, but regardless if u make it or not, u could be wishing some level of validations towards it
git centric approach to configuring anything usually has a level of more... reliability, self documentation to it, reproducing, everything
tldr:
Consider possibility of workflow. U need extra feature in kernel?
open git repo, searched necessary option (may be even with your tool made), run tests, git commited, CI ran tests
Once u confirmed that CI run is succesful, applying automated deployment to where u need it
Perhaps with this approach u will not even need the tool u originally considered?
if all validations to correct running will be present in gitops approach like that and validated, u will have reliability that everything is turned on as it is (if main concern was that)
and it will be lesser effort each time just checking which features to turn on from documentation search
Of course
OS just a program.
I didn't quite understand the second question. The CPU starts in 16 bit real mode. This is real mode and all physical addresses are real. Segmentation is mandatory for x86. You are using virtual memory as segmentation. Virtual memory is available in 32 or 64 bits. There is also something called protected mode.
Virtual addresses are used by an application program. They consist of a 16-bit selector and a 32-bit offset. In the flat memory model, the selectors are preloaded into segment registers CS, DS, SS, and ES, which all refer to the same linear address. They need not be considered by the application. Addresses are simply 32-bit near pointers.
Linear addresses are calculated from virtual addresses by segment translation. The base of the segment referred to by the selector is added to the virtual offset, giving a 32-bit linear address. Under RTTarget-32, virtual offsets are equal to linear addresses since the base of all code and data segments is 0.
Physical addresses are calculated from linear addresses through paging. The linear address is used as an index into the Page Table where the CPU locates the corresponding physical address. If paging is not enabled, linear addresses are always equal to physical addresses. Under RTTarget-32, linear addresses are equal to physical addresses except for remapped RAM regions (see section RTLoc: Locating a Program, sections Virtual Command and FillRAM Command) and for memory allocated using the virtual memory manager.
so
virtual -> linear -> phy memory.
// it is for x86. Not others.
I think I understood the second question. That is correct but IDTR is not avaible in 16 bit mode.
Actually this 16 bit mode is complete nonsense. Nobody buys 9950x3d and installs DOS in it. It is protected for historical and backward compatibility reasons. That is why segmentation exists.
i want someone to confirm if my understanding is correct:
When someone presses a key on the keyboard, for example the letter "A", the character goes to the keyboard controller, where it's stored in one of its registers.
Then, the controller sends an interrupt request to the CPU.
The CPU checks the Interrupt Vector Table (IVT), which was placed in RAM by the BIOS.
But in order for the CPU to know where the IVT is located, it reads the IDTR register to get the IVT address.
After finding the interrupt address, the CPU jumps to the BIOS code that handles the keyboard interrupt.
Then, the CPU reads the character from the I/O port of the keyboard controller, where the character is stored.
Finally, the CPU stores the character (e.g., "A") somewhere in RAM.
Is that correct?
With python for android can i include ask the extra modules required in my apk? I have an app already and in just trying to launch a python repo
this probably isn't really the right channel for this question, but yes, you can include additional python modules that your project requires in the apk
This was the recommended channel lol. Do you have a better channel suggestion?
I'm kinda stumped on my project
there isn't a channel for mobile app development on this server as far as i know, might be because it's not something python is that very good for, but it is doable
so, what are you using right now for developing and building the apk?
Right now I'm using chaqoupy which gets me about 60 percent of the way. But that's proving to fall short. I've already got an apk which I just use gradlew to build. I've added chaqoupy and it seems like a good option except it's missing pydantic v2 and I'm not sure about building the wheel for.
I'll get a link of the project
https://gitlab.com/modding-openmw/umo/-/tree/master/src?ref_type=heads
This is what I want to run.
This is my repo to build it
https://gitlab.com/cavebros/openmw-android-docker/-/blob/Chaqoupy/payload/build.gradle.kts?ref_type=heads#L35
I'm just curious if building python library and the modules myself is a better option
The apk from the main branch fully works. This is just to add the mod manager
i've only really looked at kivy with buildozer, or beeware or just a little on flet
But those create entire apps yea?
yeah, in python, what is it you want to do?
Just run the script, my apk is a full dynamic game launcher. I want to run the python main() function that so run the full mod list Downloader. All the code to display it in the ui is done, I just can't get the script to fully run from missing pydantic v2, and also struggling to get def open_url to trigger the browser
The script currectly uses xdg-open for Linux
sorry, i don't know how to get python running on android without those build tools and frameworks I previously mentioned
Ok thanks
It's definitely tricky and there's not much info
Not much i can understand anyways
Are integrated components like the network card, USB controller, and onboard sound card all connected through the PCIe bus?
Some things are pci, some are usb. See lspci and lsusb
Why do you have green background? Oh is it just the text-background? Sounds like you should configure your ls colors. Probably depends on what shell you are running. Have you tried searching for "ls colors"?
- try by just changing the theme of your terminal.
- there are aliases out there that can help you to change the way colors are used in the terminal.
- there are things like oh-my-zsh that helps you to customize the way your terminal looks.
i use arch (btw) and not just for the meme tbh
I use ubuntu
i was using fedora then went back to windows 7 for games but now im stuck doing devel on windows (i can dual boot anytime i just wanna see when will this thing fail)
The motherboard comes with a pre-divided address space - meaning certain address ranges are allocated for RAM, certain ranges for I/O devices, and certain ranges for BIOS, etc. But the processor just puts addresses on the address bus that's connected to all of them. Based on how the motherboard manufacturer divided the address space, when the processor puts an address on the address bus, the processor doesn't know what this address belongs to - but this address gets routed based on how the company that manufactured the motherboard determined the address space for each component.
For example, if the address space allocated for RAM is 8GB, I can't install 16GB of RAM because that would exceed the allocated address space. But I can install less, like 4GB. Is this the correct understanding?
I use it cuz if i switch id be endlessly trying to use yay -S to install things
why does my discord eats up so much memory
not only discord, somtimes even firefox with 2-3 tabs makes my lap go brrr...
Because Discord is Browser based app, Electron thing
basically it is having Chrome/or some other browser under the hood
and for browser it is normal to consume up to 1gb+ of ram per single tab in heaviest cases ๐
whaaaaaat angryglitch
I thought electron apps are supposed to be light
damn
comparatively.
Skype in C++ was fast and furious. Skype in electron became a lagging crap.
Vscode browser in electron is quite fast and light, Jetbrains IDEs in Java manage to be way more heavier and slower
So... it is smth of the level
C++/Rust is super fast, C#/Go slower, Electron is slower yet reasonably fast, then Java (but in some cases Java faster than electron), then PHP/and other scripting go and then Python
Despite whatever language is used devs could be lazy and not optimizing their stuff properly, in this case things can be slow in any language ๐
I see, thank you.
Does "Memory Mapped I/O" mean, for example, if the CPU is 32-bit (so the address space is 4GB), the BIOS can allocate 3GB of addresses for RAM, and when the BIOS does enumeration, it gives each device (like the graphics card) an address range from the remaining 1GB of addresses?
So basically, the term "Memory Mapped I/O" means that you take part of the address space that could have been used for RAM, but instead you assign it to a device (like the graphics card).
This way, when a program sends an address, the CPU checks if it belongs to RAM or to the graphics card, for example. Is that correct or not?
Why not use the browser instead of the app. I'm not sure the app is really much more helpful.
Did they switch to electron when microsoft took over? I remember that period after they bought it out and you literally couldn't use it anymore. It was extremely slow.
https://www.osnews.com/story/30585/microsoft-kills-win32-skype-client-in-favour-of-uwp-version/
https://www.reddit.com/r/skype/comments/fkj19n/skype_uwp_is_dead_long_live_electron/
Originally it was made in C++, with some kind of Delphi mix?
They remade it to UWP (highly likely C# based) in 2018 year already, and they faced performance issues ๐ค
And in 2020 year they remade it to Electron
I remember it became usable after a while, yeah, but I also clearly remember how they destroyed it back then. It was striking.
it was serous of sabotage both on Desktop and Server side looks like
UWP tech was crap already in 2012-2020 era of Windows 8 when they remade it to it, but they remade it even crappier version in Electron since 2020
But besides sabotage of Desktop, they also sabotaged Servers with changing from decentralized p2p to centralized Azure servers ๐ค
https://arstechnica.com/information-technology/2012/05/skype-replaces-p2p-supernodes-with-linux-boxes-hosted-by-microsoft/
https://www.theverge.com/2012/5/1/2992341/skype-replacing-p2p-supernodes-hosted-machines-security
Micro$oft in all its glory
๐
3-4 years ago i unfortunately had to try Teams
That was such a lagging glitching crap back then as a desktop client (that crashed for me somehow in addition)
not really enthusiastic to install or try it again
I've yet to see a company organise interviews other than in teams... it's pretty insane ๐
they're all Microsoft full on.
Thanks gods both companies i am in, run on Google meets / Slack / Telegram and Jitsi stuff
all tech works excellently fine without big complains
i guess except i still haven't figured out how to work with desktop Slack well ๐ but its browser version works good enough to me
unix
Hi everyone,
I built a small tool to save clipboard history. I often copy an API key and then accidentally overwrite it by copying something else in between. So I created a lightweight Linux service that pulls the clipboard content every 500 milliseconds in the background. You can use it just like git stash with commands like hcp list to view clipboard history and hcp <index> to retrieve a specific entry.
Please see if this could be helpful for any of you. https://github.com/Agent-Hellboy/hcp/releases/tag/v1.0.0
Full Changelog: https://github.com/Agent-Hellboy/hcp/commits/v1.0.0
Added a new release, now I am directly using X11 instead of via xclip
bad developers
What about non-x11 desktops?
Yeah, working on it
Wayland based system
Also, you should respect xdg directories. Store your database file in ${XDG_STATE_DIR:-$HOME/.local/state}/hcp/history.block
And it's default in Ubuntu 25.04
I think with wayland, you'll need to use the dbus to listen to a copy event
Wayland doesn't allow background sniffing, I am working on pocs to resolve the security aspects
Yeah, I have created a ticket
Thanks man, I will explore this.
Any other suggestions?
FYI KDE plasma has a clipboard applet
Yeah, there are a plenty of open-source projects out there, created this for learning only.
Guys i need help in bash anyone?
If you ask a question you are more likely to get an answer ๐คฏ๐ค
Tf are ppl keep using this trash system
Say something meaningful
Lol if Unix has meaning i will ๐
I can teach bash and u will be a hacker u can steal banks and attacking complexity security systems
I will teach bash. curl is a separate topic.
Did u found it????
Find what?
a way to cope with the OS ecosystem's current state, perhaps
It's called python
Bash is a nightmare, I have yet to abandon it ๐ญ
The idea of the GDT is that I define the address of the code, where it starts, like from address X to Y, and the data has a size from this to that, and the stack has a size from this to that, so I can enter Protected Mode. All of this is set up just for the code, data, and stack, so when the Kernel executes, it determines the size of all these based on the Kernelโs own size. In other words, I allocate fixed parts of the RAM for the Kernel, which is the operating system. Is my understanding correct?
v5.3 just got released
You can now capture a process without a subshell
x=1
out=${ x=$((x + 1)); xxxx; }
echo $x # 2
echo $out
What did you have to type before?
I don't think I'm getting new bash very soon. My other reasons to trying to switch to fish or zsh is syntax highlighting.
But mainly I'm just tired after going long wrestle games with PROMPT_COMMAND and tty settings after trying to run the command fg as a keybinding ๐ญ๐ฉ
You would use $(xxxx), but assigning to x wouldn't apply in the parent shell
Ah! ๐
I have no idea how mailings lists work (and especially bash's archive of it) . but I'm scared of bash 5.3 as since this discussion I started last year will have new behavior that was more annoying to me ๐
The one piece
bash is great, y'all just lack good taste
bash is trash
srsly I only stopped using bash interactively after Apple strongly encouraged me to move to zsh. I still use it for short scripts, though
the interactive shell i use is almost always bash on linux, which is my main OS
and zsh on mac just because it's the default there
i don't think it's such a big deal or such a big different really (then again, i don't spend so much time on macOS and hence zsh)
but for scripts i try to go POSIX compliant or just use bash specific features when POSIX is too much of a hassle or drawback, bash is available in most unix like environments today anyways
It's the old tradeoff: portable code vs. portable runtime
Cap
Hello
!tvmute 1340518774423421001 14d Spamming is not the way to pass the voice gate, as you have been warned in bold letters in #voice-verification
:incoming_envelope: :ok_hand: applied voice mute to @deft stirrup until <t:1753958012:f> (14 days).
Why
I have set up so many helper stuff in, otherwise I would already be on fish. But also most colleagues use bash and it's valuable to use the same.
Things I have wrestles with is Job management (trying to figure out if vim is currently open and running or in the background) , trying to understand tty and realizing fg shouldn't/can't be run from a keybinding.
Also by default it doesn't:
- show return value of last command
And I don't know if it supports:
- have abbreviations
- syntax highlighting
Setting up the prompt is quite complicated as I had to learn about bash arrays and PROMPT_COMMAND
Hi
I too had a ton of little shell functions and whatnot, but was able to switch to zsh without too much trouble; it turns out that I didn't really need most of those functions, and the rest were pretty easy to "port"
if you like fancy prompts, you should check out https://github.com/romkatv/powerlevel10k and https://starship.rs/ for zsh
my current zsh prompt, e.g.
Yeah, no I don't really like those prompts, it's a bit too much. I have something dedicated for my work environment. Depending on which of 2 to 3 modules are loaded. Plus git info of course ๐
I only tried starship I should say.
Not sure how they would interact with direnv and nix-shell. I guess there is a chance they fix things, but I would rather haver fewer moving parts to debug ๐
@rotund girder Hey, I've recently found you making comments on an old uv issue (the one about human-readable rule names). Did you ever end up working on that; or do you know what the status of it is? I can't understand it from the ticket.
need help : i am using linux mint cinnamon, with gnome terminal. I have made my terminal transparent but don't know how to add the blur effect.
Do you mean this ruff issue? https://github.com/astral-sh/ruff/issues/1773
I know about it, but it doesnt seem to mention my name? And no I don't spend time to develop in my free time, I stop at filing issues ๐
Yeah, I meant this comment. Alright then..
Oh right, needed to expand the list
I guess I saw myself having some free time ๐ no I haven't done anything. You interested? ๐
Interested in having it solved, yes. ๐
Me too ๐
(not really interested in working on it right now)
I was just asking because someone commented that apparently they (astral) want a different solution and I couldn't find what that means.
@spark mulch I just found this short discussion: https://github.com/astral-sh/ruff/pull/11757
So it might just be that they want to decide on the details before continuing. But I think they are focusing effort elsewhere still.
I've been hoping for stable pycodestyle lint rules for a long time ๐
was wondering when that was gonna land
apparently ruff lsp allows looking up the definition of codes
outing myself as hyper-noob here but....ok so JUST learning Linux on ubuntu with WSL and occasionally I'll mess up a command and it gives me nothing but ">" on the screen and not returning anything so matter what I type. How do I get back? (Also appologies if this is not the right pace for this kinda question)
> means it's waiting for you to continue typing your command, this can happen if you forgot a closing qoute for example
echo "test
it can also happen if you put a backslash at the end of the line \ and bash will let you continue typing in a new line (are you accidentally pressing \ before Enter?)
yeah, thats actually exactly what I did. Forgot to close quotes which sent it to that. Cant seem to get it to return though, even replying to echo commands. Just comes back blank
you can cancel it with Ctrl-C or end the command with ;
ah, ctrl c worked. Hoping I eventually get to a level where I roll my eyes at asking this question ๐ Thanks a million!!
it's fine, we've all been there at one time in our learning process
Ctrl-d is another one that can be good to know. It means "end of input" (end-of-file, EOF)
Is it important to start ssh service in the beginning of learning Kali or not important?
I am using Kali as a VMWare btw
i don't even get your question, the ssh service is used for you to be able to access the system remotely with an ssh client
also, Kali linux is not a good general distro unless you are doing cybersec stuff specifically, if you're not doing that specifically you should reconsider your choice of linux distribution
I am doing cs stuff for sure
CS as in Cyber Security and not as in Computer Science, right? ๐
okay, if it's for cyber security Kali linux is fine ๐
but if you want to use it for general linux usage or development i would recommend something else
cybersec yeah and I learn terminal
learning to use the shell/terminal/command line isn't specific to cybersec and can be done on mostly any linux distro
but sure, i'm guessing you're using utilities that aren't typically installed by default in just any distro but is in Kali
I learn kali tools too and networking
I'm an expert in chromeos
please remove that and don't post things like that here on the server
!warn 1365315568533639168 Don't post malicious commands here
:incoming_envelope: :ok_hand: applied warning to @main olive.
got a warning :c
hello
meow
Helo
yo
Whats up
r u also new here
yeah
i am here not for learning bc i hate python( why bc it's really slow )
just for having some fun
Aha ๐
Na I'm a beginner
ohh i see. i really don't know anything about python but i can learn it so fast
On the way to be one
i am dev on: C++ , Rust , my lang , Luau , PowerShell , Batch , LLVM APIs
good luck dude.
Crzyy that's good
tysm bro!. for that i can easily learn python bc so simple
and help you learn it too
Thx will tell you fs!!
alright. need anything i am here tho
i think you don't care it's alright O_o
For now it's simple don't think the help needed for now
Ahmm no was thinking bout what was u telling ๐ถ
alright!
ohh mb. i am kinda scare to talk about my lang
So i am so new to some terms they r going above my head
POV: mods right now looking at my msgs
wdym?
Like so u created a lang
Right?
Hm I think firstly i should learn something bout coding so I can understand basics
I'm totally new, u know
Switching so quick is difficult for me
Also I have to ask one frnd before
Will do wht he says
ohh i see
tip. start with luau
is simpler then python and will let you learn the basics
you have luau ( soooo easy , but DLS ) python ( not that easy , but GPL )
Okk thx for ur time ๐
i am sure you didn't understand what i said
i mean: DLS = lang use for 1 thing like game dev
Yes ๐๐
GPL mean lang use for very things like web AI apps etc...
Ah
Like for ai area python is good
python is good for AI. but only problem python is slow. but tip use python. after you be in good level. go to rust is so fast and good on AI
Ah okk
And is machine learning linked or that is something else
if you mean about rust. is like python AI but better X999999 time
Um so i should switch to rust in future
yeah. but stay time with python bc rust kinda hard
Can u tell the difference between llm ,api
lis idk how to say it but i will try
API like you have a computer you send the data ( input ) and do the work and get you the ( output ). use most time for bridge between 2 programs
Gottcha
so API use every where
you right now using API
your pc , discord , browser , internet , all use APIs
Last que
Like after python what I am going to have skills in
about LLM. is an AI that understands and generates human like text. like you have so much data give it to AI => Result text you can understand
python can use for: Apps , High level ( mean like apps , games etc.. ) , web dev , GET MONEYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYY , get skills , and easy
don't thank me tho, i love help others. need any help dm me
last thing. never give up
Ok cya
cyaa
Hey, can you help me also. I am junior dev and struggling a lot understand the codes. As we need to use AI tools to give fast result, my learning is taking a toll.
hi
Whats the difference between Linux and Unix?
Unix is an old and historically very important operating system dating back to the 70s, and the term is also used to mean operating systems that are "unix-like" in their design. Linux is one such operating system, which is open source and available free of charge, unlike Unix which was a commercial product
why is there a unix channel if its soo old?
Wouldnt it be linux instead
The channel name means "unix-like"
oh
So it's not just Linux, it's anything descended from Unix including BSD and MacOS as well as command line tools and other details that are common across descendants of Unix
Which linux is used most in industry?
headless
Hi
is it not allowed to install linux on macos?
you're still getting machines and operating systems mixed up
Mac -- a brand of computers
MacOS -- the operating system that comes with Macs
if you buy a computer that comes with Windows, you can make a separate partition and install Linux on that. That Linux partition isn't "linux on windows". it's a separate partition of the computer itself, and linux is talking directly to the machine. not windows.
make sense, @abstract narwhal?
dual boot?
is it not possible to single boot?
single boot is sort of the default
are you wanting to fully replace windows with linux?
yeah that's what i said
dual boot is slow
people told me
is this on an older laptop, or something like that?
no, dual boot isn't slower compared to a single boot. you only have one OS running at any given time.
what you reduce is disk space.
I wouldn't replace the OS on a brand new machine.
you can make linux VMs
yeah but still two OS are using disk space
yes, but that doesn't make them slower.
yeah i'm thinking of it
only one is using it at a time. that doesn't slow it down.
i have 8gb ram
ohh fine
Dual booting linux on a new Mac is going to be a challenge beyond just learning Linux. I think you will have a much easier time if you use a dedicated cheap computer like a raspberry pi, or use a virtual machine
i have a dell laptop also
Just getting Linux to run at all on a newer Mac has been a substantial technical achievement, look up Asahi Linux
should i get linux on that
That's more likely to be an easier experience, but you should download a Windows recovery installer and create a recovery USB just in case you want to go back
you can also learn all the relevent linux stuff that a regular dev needs on your macos , you dont have to install a seperate linux distro
ubuntu doesn't work on mac?
Note that laptops can be challenging with Linux as well
they're on a mac
They just said they had a Dell as well
how
Ubuntu is a variety of linux
I recommend against installing on a laptop for your first intro
is ubuntu not for arm architecture?
because they are similar in nature
Probably the easiest way to get started is to just use Docker Desktop for Mac
what's this
I feel like you're bouncing around between questions without waiting to understand the answer to the question you asked already
please stop trying to shove more and more buzz words , you are making a salad of all the words
no
docker , kubernetes and many other dev things work on linux
not on mac
says who
and don't even talk of windows
they work on windows too , just fine
Running Linux on Apple Silicon Macs needs substantial changes. Asahi Linux packages them for you in an integrated distro.
Ubuntu does have ARM64 builds, but Apple Silicon is not a standard ARM64 environment.
you said asahi linux works on newer mac
and not others
since m1 chip
there are many things which you can't do
ohh gawd
Docker Desktop for Mac runs Docker in a QEMU VM
does ubuntu have x86 architecture distros?
i think i'll have to work on dell now
such as ?
๐ญ
x86_64, but yeah, of course
that's the most mainstream
you can setup your dell as a headless linux machine and ssh into it using your mac
omg
what's this stuff
so i'll have to carrry two laptops everywhere i go?
for the stuff you are saying you need to learn , you dont need a different linux distro at all
you can do all of that on your mac
i want to experience full fledged linux
you're not out of options
you could use a VM
i don't want to miss out on anything
then use your dell to get a feel for linux
yeah that's the only option
VM or dual boot
VM doesn't allow many things
dual boot allows
but it consumes disk space
i'm cooked from both sides
๐
I like to use macbook๐ญ
it's touchpad and keyboard is better than dell
what kinds of things?
That comparison table is suspect
As far as I know, being in a VM doesn't affect cgroups features at all
I wouldn't expect significant limitations in sysfs either
โฆwhat is Kubernetes cluster realism?
200k dollar job skill
You can still experience it with macOS. They're both unix-like.
bro
What do you want to do with it? Maintain your OS yourself?
If so yeah, you won't be able to do it
no , its some BS chatgpt made up to sound convincing
yeah that's one of thing
and there are many dev things which are not in macos
It seems like you have already made up your mind
no i'm searching
i'm still not sure
that whether i should switch to linux
from macos
Couldn't you just run a Linux VM on your macOS machine if you need to do one of those things?
Plenty of people run Linux containers on macOS using Docker
linux VM runs slow on macos
actual performance of mac reduces
Is the slowness noticeable?
also you don't get many features in linux vm
Because I definitely haven't noticed it
which you get in complete linux os
Lasts a day
Good enough for me
I've never heard any of my coworkers complain about Linux VM slowness, but - even if it is slower, so what? You're looking at using it for Linux features, not for speed
are you using linux vm on macos?
Yes, for Docker
i want to work on linux
sure. You can do that with a VM
nice
Again, is the slowness noticeable for you?
most code is IO bound, not CPU bound. VMs don't introduce any slowdown for IO bound work. And modern VMs introduce very little slowdown for CPU bound work, tbh
if you run your software in the cloud, it's running in a Linux VM
M1. 16 GB.
you might be thinking of Rosetta, tbh
there's a pretty big slowdown for emulating x86 on an arm macbook
I'm mostly running arm64 containers, though, yeah
yeah. If you've got an arm macbook, run arm containers, not intel ones
what
it's running on linux OS
VM just has linux
yes, it's running on a Linux OS, running in a VM
that's not where every software running
you can run without VM
it needs linux OS
not VM
not in the cloud, generally
cloud offerings are basically always virtualized
i have m2 8gb pro
cloud baremetal is expensive
the overwhelming majority of backend software runs in a VM these days
it's been that way for at least a decade at this point
anywho, if you really do want to run Linux outside of a VM, I'd strongly recommend not doing that on your macbook. I'd buy another machine to install it on
Apple isn't particularly open with their hardware specs, and don't write Linux drivers for their custom hardware, so the Linux drivers for Apple hardware tend to be buggy and feature-incomplete, based on reverse engineering by hobbyists
If you're getting this info from that ChatGPT table, it's plain wrong
and this goes double if this'll be your first time trying to run Linux. You'll save yourself a lot of trouble doing some research up front and picking a device to install it on that's well supported
the one thing it's probably true for is AI/ML. If you want to do something that has access to your GPU, you probably don't want to be using a VM for that
nowadays [some?] nvidia hardware even supports vGPUs which allow multiple VMs to have simultaneous direct access (pass-through) to a single GPU that they can share, magic stuff ๐คท
interesting, TIL
I've never actually needed to do any GPU programming, so everything I know about it is second hand
it's probably mostly aimed towards hosting, could infrastructure and enterprise environments from the looks of this https://docs.nvidia.com/vgpu/latest/grid-vgpu-user-guide/index.html
but the supported hardware seems to range from quite normal workstation Quadro RTX GPUs and upwards
on the software side, host support seems to range from KVM, XenServer, Proxmox (found that last one on another site) to vmware vsphere
sure, you could probably get it up and running in a homelab with the right hardware and software and licenses, but it won't be a cheap setup
should i switch from windows 11 to ubuntu, like are there any cons?
Depends on the apps you use. most of the stuff is ported to Linux or has a decent substitute, plus it's all browser-based these days anyway.
Unless you're deep into Adobe's cough products cough, you'll probably be fine and you'll learn a lot in the process.
why do you wanna switch ? just trying it out or is there a specific reason ?
very much depends on what you use your computer for
if you play different PC games you might find that quite a few of them doesn't run on linux
or as it was alluded to above, if you really need to run certain apps that isn't cross-platform or have a good alternativ on linux
if you just want to try out or learn linux, WSL2 inside of Windows is often more than enough or something like a Raspberry Pi would also work pretty good for basic things
Has anyone here tried using FreeBSD as a desktop OS? If so, what was your experience like?
I've been thinking about migrating my handful of self hosted services to some BSD variant and using jails instead of Docker images. But I really appreciate the BSD base system + ports model and it seems appealing for a desktop OS
I haven't used solely as a desktop OS but I did have a machine that I was doing a lot of work on
it is pretty decent how much is supported on FreeBSD actually
I was using it probably 3-4 hours a day, had KDE running on it etc., things were pretty smooth
& yes, jails are fantastic
there is a period in my open source project history where all my projects have deployment instructions based on BSD jails rather than containers ๐คฃ
so overall yeah, I can definitely vouch for it, it's a different experience but if you're willing to put the learning effort in and accept that some things are going to be a PITA that are easy on other systems it is very rewarding
is icecast mispelled at the end of this
I am a software engineer with a BSc Honours in Computer Science from BITS Pilani. I am currently in the process of developing a Linux-based distribution operating system from scratch as a side project. I welcome anyone interested to connect with me.
yes, plus i already have a prior experience of using ubuntu terminal in my institution pcs but ive never tried it on my personal system so kinda scared what will happen if i dual boot again and again
idk i just like it more than windows, it's faster i can directly run g++ in the terminal... windows is just a little 'too much'
if you set it up on an external drive, it will be like a completely different machine ๐ช
no i don't do games i have a 1334U it can't run any good games either way, i have used linux before but not on my system so kinda scared to completely switch my main usage is coding and casual streaming
can you dm me some tutorial video links how can I set it up step by step.. that would be a huge help
See the video in the post I linked. It does a complete installation.
oh ok (although , you can run g++ directly in windows too , thats no different)
this is what i used to use too , booting to linux off of a USB NVME SSD , its nice. but a little cumbersome as you sometimes have to adjust the boot order of drives in BIOS
but it gives you power to use everything as if you had linux running on your PC
lol no good spot
hello how do i instal python?
on what platform?
Pc
mac/windows/linux?
Windows
https://python.org/ has download links to installers
Thx
yeah but i feel windows is a little too much for me if that makes sense, i just like the ui of linux its very minimalistic and fast
thanks man, really appreciate it
Linux is a kernel lmao
what Linux distribution do you use
There isn't really a "UI of Linux", just depends on how you set up your system
I mean, I get what you're going at, I have the same reason for using Linux, I just really like Gnome
other factors are in play but that's just a part of my "emotional reasoning"
I'm dual booting because I don't have a strong enough reason to completely leave Windows
I moved because I like Linux, not because I hate Windows
mb for the messege my acc got hacker but the guy didnt knew i do cyber sercurity
@zinc pivot use wsl sub system for scripting it's more convenient
But it's partially has slightly lost in efficiency
Powershell is nice
powershell has some nice ideas
huh, never realised how fucked library resolution for libraries from homebrew is on apple silicon macs
there is almost no way to have python pick up libraries installed via homebrew because the variable that python looks for is purposefully removed by the shell
?
Homebrew patches their Python versions it seems so it's not so bad, but out of the box with, say, a uv env you cannot use libraries installed from homebrew
I have the vague sense that
bzzt, wrong; it clearly is ๐/opt/homebrew/libis not the right folderwhen youI probably am thinking of something else -- finding executables on PATH, maybe ๐brew install whatever, it typically prints out a message like "to use these libraries, add /opt/homebrew/lib/Cellar/whatever/3.2.1/ to your library path"
/opt/homebrew/lib symlinks to the cellar files
yeah I just noticed that
whilst i was struggling with this I did forget that homebrew is not like apt and does make python versions available at reasonable times
odd that I've never run into this myself. Perhaps when I uv install some-fancy-package, it installs the shared librairies for me, and fixes up the LD_LIBRARY_PATH too
so I guess the solution is to just ensure you're always backed by homebrew versions of Python and to stop uv trying to pull it's own versions in
heh
I think in these cases it's alright because the linker path is unaffected and passed to child processes, it's only that SIP prevents the DYLD variables being passed which ctyles.utils.find_library explicitly depends on
I obey this
There are many ways to get Python installed on macOS, but for most people the version that you download from Python.org is best.
yeah I think "uv" is automagically taking care of things: ```
/Users/not-workme/.local/share/uv/:
find . ( -iname *.so ) -ls
111908319 52 -rwxrwxr-x 1 not-workme staff 50784 Feb 2 2025 python/cpython-3.10.16-macos-aarch64-none/lib/python3.10/lib-dynload/_crypt.cpython-310-darwin.so
111908320 76 -rwxrwxr-x 1 not-workme staff 75232 Feb 2 2025 python/cpython-3.10.16-macos-aarch64-none/lib/python3.10/lib-dynload/_testclinic.cpython-310-darwin.so
terminal talk!
hello
ghostty +show-config --docs | prettybat --language yaml
piping to bat made it readable
bat wrapper.. i use it for code, but this config was not triggered..
an arch fork of bat? (https://man.archlinux.org/man/prettybat.1.en)
i think --lanuage yaml is wrong
no its a bat thing
like nedbat? ๐
unbuffer ghostty .... | less -R should also work, right? Then you should get the correct colours
ghostty: where scrollbar?
ghostty config has no specific config file format, it's entirely custom, it's just plain foo = bar's
or was it foo: bar i don't remember
i dont know.. let me install unbuffer...
well.. cat should work right?
(unbuffer to trick Ghostty into thinking it's displaying things on a TTY, and -R to have less output the raw data, instead of escaping ANSI codes)
tino/proc.h:511:3: error: too many arguments to function โIGURโ; expected 0, have 1
511 | IGUR(ret);
| ^~~~ ~~~
In file included from tino/file.h:102,
from tino/buf.h:33,
from tino/buf_line.h:26,
from tino/main.h:26,
from tino/main_getext.h:26,
from unbuffered.c:9:
tino/debug.h:121:18: note: declared here
121 | TINO_INLINE(void IGUR()) {} /* see http://stackoverflow.com/a/27672750 */
| ^~~~
tino/sysfix.h:47:39: note: in definition of macro โTINO_INLINEโ
47 | #define TINO_INLINE(X) X; __inline__ X
| ^
In file included from unbuffered.c:14:
tino/signals.h: In function โtino_siginterruptโ:
tino/signals.h:64:3: warning: โsiginterruptโ is deprecated: Use sigaction with SA_RESTART instead [-Wdeprecated-declarations]
64 | if (siginterrupt(sig, flag))
| ^~
In file included from /usr/include/sys/wait.h:36,
from tino/proc.h:19:
/usr/include/signal.h:324:12: note: declared here
324 | extern int siginterrupt (int __sig, int __interrupt) __THROW
| ^~~~~~~~~~~~
make: *** [<builtin>: unbuffered.o] Error 1
==> ERROR: A failure occurred in build().
Aborting...
error: failed to build 'unbuffered-2.2.0-1':
error: packages failed to build: unbuffered-2.2.0-1
๏
ผ ๏ ~ ๏ 11s ๏ 15:17:33 โโฎ
โฏ
```\
they don't have that yet? i've been waiting for search
What's the problem with just running ghostty ...? Does it automatically display stuff in a pager?
usually | cat or env PAGER=cat is what I do in those situations
sometimes, and sometimes not.. but itis all whhite on black background
scrollbar, not searchbar, but it seems like both are missing?
Ah, I thought it was displaying colours by default except when piped
ya i know you said scrollbar, i meant i was additionally waiting for a search bar
not showing.. just trying to trick it iinto shhowing me...
oh and trackpad gestures, once ghostty has that i'll finally fully migrate to it from apples Terminal.app
Oh, I see. I misundertood the issue then. No need for unbuffer
doesn't ini/toml/yaml work?
yeah... im just experimenting with languages
whats the uv tool command to install black globally?
uv tool install black i believe
btw session management is the top requested feature in ghostty https://github.com/ghostty-org/ghostty/discussions/3358 and if/when that lands tmux will essentially become obsolete in ghostty
nice... prettybat uses black under thhe hood.. neat
i think most package managers have something along the lines of python-black
fancy.. just like in the other one
alacrtitty
i dont touchh my os for python stuff
uv is god sent
i love uv
wish it was made sooner lol
im testiing uv now siince i already have a new machiine setup
im very slow to move over to new tooling
but once ii do, i go all in
in that case perhaps you should try ruff instead of black 
that's made in rust right?