#unix
1 messages · Page 8 of 1
ok doc here is the tree https://en.wikipedia.org/wiki/Unix-like
A Unix-like (sometimes referred to as UN*X or *nix) operating system is one that behaves in a manner similar to a Unix system, although not necessarily conforming to or being certified to any version of the Single UNIX Specification. A Unix-like application is one that behaves like the corresponding Unix command or shell. Although there are gen...
If that tree is true then Linux is distinctly not UNIX
but its unix like 🙂
ah yes
So no Linux question please on this channel 🤣
see the channel description 🙂
Im trying but i cant seem to figure that out 🙂 but the channel is UNIX# and there is no LINUX# so just saying that Linux is way more popular now than UNIX
UNIX is dying
not a big deal just trying to highlight a fact that UNIX is not what people typically chat about here. Mac is an outlyer in todays world of servers that we typically called 'linux servers' not 'unix servers' so channel name should reflect reality that im aware of perhaps #unix-like
In all honesty I'm pretty sure this is just #not-windows but "unix" fits better
Yeh might agree but Linux is a totally free platform where UNIX is not. Some party may get a legal wedge to suck money from you. That is why we have all these legal copyleft and anti-copyright laws combating UNIX ware
#FREE-UNIX might be a nice name 😄 and for window #unix-IS-FILTH
There have existed Unix certified Linux distros, though I'm not sure if there are any modern ones
What is a Unix certified Linux used for ? if seriously you have some mission critical app on UNIX now, i need to move accounts away from that entity.
Inspur K-UX is a Linux distribution based on Red Hat Enterprise Linux produced by Inspur, a Chinese multinational company specializing in information technology. Inspur K-UX 2.0 and 3.0 for x86-64 were officially certified as UNIX systems by The Open Group.
I read most of the 2 links you present but they dont Legally define what is UNIX and what is more important also what is not UNIX.
we know what Linux is because its legally defined
but UNIX is lose
More than that why do i care that they are UNIX complient ? (reword) Linux is what most of our financial flux plus most of our PnL is worked on today.
what does it mean to say MySql Is UNIX complient these days. what is the standard to install MySql in UNIX ?
UNIX certification is something that you can pay The Open Group to audit your code for. They give you the certification and let you legally call your thing a UNIX if they agree that it meets all of their criteria
There's absolutely no good reason to do this, which is the reason that UNIX certified Linux distros aren't common. I'd expect any distro could get certified easily if it wanted to, but there's no tangible benefit to doing so, and there's a significant monetary cost to pay for that external audit
If I had to guess, those 2 UNIX certified Linux distros probably got certified because they had some big contract that hinged on whether or not Linux is UNIX - probably some customer who was only allowed to use a "real UNIX" because $reasons, so they had to pay someone to say "yes this is a real UNIX" in order to land that contract
I agree that this is money talking (and it always does) so for us it does not matter on this channel and it is an outlier that all of us (and most companies) will not benefit from.
so the the challange is that unix is not linux and apart from big money it stands true ?
If your question is "is Linux UNIX", the answer is "sometimes", as these distros show.
If your question is "does it matter if Linux is UNIX", then no, not really
I would ask ... if this was a population of 100 million functional instances of linux what percentile is the group you are talking about?
Very low
That doesn't seem relevant, though. Clearly Linux can be UNIX, and if it was worthwhile for Linux to be UNIX, Linux would be UNIX more often. The only reason why Linux is rarely UNIX is that it's rarely worthwhile to go through the certification process
Gotcha. Well for what its worth i think most Linux users know that ill-informed people will refer to it as UNIX even though it totally not and legally separated from UNIX because of good reason. and the only reason that there is not a GNU version of an OS is because they gave up, and that was the movement of free software that we all pay nothing for today ...
its good to be not UNIX
It's not "because of good reason" - that's exactly my point. It's totally arbitrary. The people who legally are allowed to grant you permission to call your operating system "UNIX" will let Linux OS's call themselves "UNIX" as long as you pay them to audit your OS. There's no good reason why Linux isn't usually UNIX, just a silly one
If it was free and accessible, every Linux would be UNIX. Because it's expensive and not very accessible, the overwhelming majority of Linux systems aren't UNIX, because they meet all the requirements to be UNIX but the UNIX authorities haven't confirmed that.
ok not sure you understand the legal standing of UNIX vs Linux. if a company can site a code pattern in your code-base that they hold a US or other patent on (under UNIX aka bell labs or att ) and you profit from that code, you are going to be in a civil case in the US. This is a regular thing and its a business for lawyers to make money on. so the founders of free software has dissected itself totally from UNIX to guard us all from this.
So its good to be not UNIX
You're talking about copyright violations, I'm talking about trademark violations. Something can use the UNIX trademark even if it has no code from the original UNIX OS's, as long as the people who own the trademark (originally AT&T, later SCO, now The Open Group) say that you can
Ok so we aggree its totally not something that we care about. its just some business man who wants to check off a UNIX complient box.
i mean if you have a 25 year old solaris 5 box its not running linux is it ?
yeh its not
Yet that box is UNIX complient
lets take that further is is SUNos 3 complient that is UNIX
its meaningless
No, it isn't. Not UNIX certified, doesn't meet the UNIX 98 requirements, etc. At least, AFAIK
they are not totally different but they are protected by law to be differnt
Maybe the trademark owners would give it a pass because modern Solaris versions are UNIX certified, though.
Solaris is only in existance because no devs have actually made the cutover to Linux
there are lots of cobal devs that are dying and that is the only reason there is dev time to convert that code too. UNIX is dying dude
Linux is dormant
totally separate and legally distinct from UNIX system
Sometimes 🙂
is systemd a UNIX standard?
The UNIX standard doesn't require any particular init system
so what is the UNIX standard distro ?
There is no standard UNIX distro
Correct
There's a set of requirements, anything that meets those requirements can be certified to be a UNIX
ok but Linux does not meet them in any form
Linux meets all of them
no its does not
If it didn't, there couldn't be any Unix certified Linux distros
The fact that some Linux distros have been Unix certified proves that Linux distros can meet the requirements to be called a Unix
sunos 3 i mean
https://pubs.opengroup.org/onlinepubs/9699919799/ documents the requirements, you can look at them yourself if you're curious.
this statement just means we can fool some old system to think Linux is a UNIX box. But you must see that this is a fools game. eventually that UNIX system will have to migrate to a non UNIX box like
Linux
No, not at all. My statement is that the people who are legally allowed to grant you the right to call your software "Unix" have granted that right to Linux distros that asked for it
so we could call Lunux a goat. is it a goat?
The authorities who define what the word "Unix" means say that Linux is one
I suppose "goat" is different because there is no authority who can officially decree what is and isn't a goat in any sort of legally binding way
can you provide that link
I did, above
That's what started this whole conversation
You seem to have an idea of what "Unix" means that's different than what the owners of the Unix trademark say it means
haha the business men that coined Linux as Unix i dont think that was really serious
there must be some merrit to it other than that
It is really serious. The business men that say that Linux is Unix now are the same ones who sued Novell for calling itself a Unix 20 years ago
Not literally the same people, of course, but they bought the rights to the name from those people
code base and the dna of that is what makes the name for me. if you want to argue that the name is transferable then ok but im not really into that .
Ok. Well, the courts disagree with you. 🤷♀️ Legally, you can get sued if you market your OS as Unix without The Open Group saying you can. Legally, The Open Group has said that some distributions of Linux are allowed to market themselves as Unix.
as they can under the free copyright but they cant then close the code .
close code is forbidden under GNU and Linux have similar stuff
Something with AT&T/Bell Labs Unix code in it that's not Unix certified by The Open Group can't legally use the Unix name. Your "DNA* argument doesn't hold any water legally, the trademark does
ok maybe but i thin Linux is not UNIX hehe and it might be an opinion but its mine
i also dont think you presented a valid argument to why Linux is UNIX
How is "the people who are legally authorized to decide what is and isn't Unix have said that some Linux distributions are Unix" not a valid argument?
You seem to have an understanding of all of this that's anchored in the dot com era. You seem to have missed 20 years of evolution here, and new positions taken by new owners of the Unix name. But it seems like we're not getting anywhere, so I'm gonna drop this discussion and head to bed.
So if i have a few years i suddenly know nothing. Im up to date man :-). ask me an up-to-date question. but you have not presented any reason why Linux is UNIX but you say that if a court said its has name rights it must be UNIX
it seems funny
linux is unix-like
Yes, the owners of the Unix name say that Unix is a set of behaviors and a standard, and Linux follows that standard and has those behaviors
if you're going by the definition of "unix is anything certified as UNIX"
And sometimes it is Unix
yes

and yet the Gnu is so adamant that its not UNIX. as its name implies can you explain why that is in the linux distro ?
strictly speaking gnu isn't necessary for a linux distro
ls in linux is not UNIX
correct its nto but its the basis of all bash tools
and it GNU
hehe
im fairly certain that busybox doesn't use anything gnu
mistaken
And the GNU userland tools generally conform to the Unix specification. They even have ways to force them to behave in Unix compatible ways when their defaults are not Unix compatible, like the POSIXLY_CORRECT environment variable
ps ls dir are GNU tools
some implementations of ps ls dir are part of GNU, yes
but there are also non-GNU implementations of unix utilities that are found in some linux distros
The acronym comes from a different era. Software vendors created maliciously compliant Unix systems to ensure that you couldn't switch to different system vendor. The acronym was born in that era, where Linux ran contrary to this, not focused on vendor lock in. These days, Unix vendors are all but dead, so the name doesn't mean a whole lot.
iirc alpine uses busybox + musl instead of gnu coreutils + glibc
oh i didnt realise that, what distros do that ?
okk disregard
Alpine is the big one
depending on your definition of "Linux", I think android also counts
To my knowledge the only gnu bits of alpine is gcc
Maybe they compile it with clang now, not sure
ok so what is the reason to break from GNU ?
Musl and BusyBox are smaller, and have more permissive licenses.
isn't busybox also gpl?
Oh yeah, so just the smaller thing for busybox
GNU coreutils are GPL 3, busybox is GPL 2 - so, slightly more permissive, at least 🙂
so again is Linux in legal tems UNIX ?
Sometimes. Not every distro, but some distros. The ones that bothered to pay for it.
considering the tree of development
iirc the linux kernel was basically written from scratch
But it was explicitly designed to be Unix compatible.
The interesting thing is that the only hurdle is the cost and time to get certified. Any Linux distro that wanted to get Unix certified could, they'd just need to pay a bunch of money
so is compatible = UNIX or not ?
No, Unix has a very clear definition. Some Linux distros meet it
i know and yes i have a few years on me that it totally not
Linux is not an operating system unto itself, rather it is a kernel, forming a complete operating system only with a distribution that provides the userspace etc.
It is generally a pedantic distinction to make, but in this case it does matter
if you do an ls -s it does seem same and it has /etc/passwd and such but it starts to diverge in a lot of ways after these superficial things
It matches all behaviors and has all APIs described in the single Unix standard.
The fact the SUS is awful and pathetically weak, due to Unix vendors wanting to get their lock-in cash, and thus being Unix compliant is not enough to give you clarity in all but the most superficial things is a separate matter.
Writing software in a way that it will work on every Unix compliant system is nightmarish, and occasionally impossible due to optional APIs. But hey, at least you get CHAR_BIT==8
Linux has plenty of things beyond the unix standard, as do all unixes, and all real-world unixes did historically
so other than a similar look what actually ties Linux kernal to a pre-existing UNIX kernal that it has to be a UNIX system. or what do you think merits that Linux is in actual fact UNIX ?
why cant it be in itself a Linux system Distinct from UNIX i mean
The fact some Linux distributions have passed Unix certification, meaning they are compliant with the single Unix standard, which defines what Unix is.
Does Unix specify Macs launchd? Of course not. Does it ever mention BSD jails, of course not. those are system specific features, just like most of gnu and Linux.
Ok where is that defined ?
Where is what defined?
Unix is a specific standard that you have to meet and get certified to be able to specifically call your OS Unix
Unix-like is more of just a term for anything that behaves like Unix, though maybe not entirely conforming to the spec, or maybe just out of lack of certification
Linux was designed to be Unix-like, which it is, but certain distributions of linux may or may not go through the process of fully conforming and certifying themselves as Unix
To be clear, the fact most Linux distros are Unix compliant is not at all useful, and you should just write code specifically for Linux systems to preserve your sanity.
But hey, if you want to write your program in a way that makes it run on both BSD and Linux and every historic Unix, and your program is extremely uninteresting, you can.
so launchd may be a reason to say that is systemd UNIX or not. Is docker a unix standard? all these things modify the kernal. if the kernal is the root of your OS is Linux a Unix systen or truly a system of its own. there are scripts that will fail on a bsd system like MAC is that UNIX ?
xcode-select --install this is a script that will succeed on Mac, and fail on BSD and Linux. (also, MacOS is not BSD, though historically it was).
The simple reality of the matter is that the Unix standards are intentionally very forgiving and as such, even between two unixes, there will be significant, major, differences, that make it quite difficult to write portable code between them. MacOS is notorious for this.
'Unix standards are intentionally very forgiving ' where is this standard dictated. wiki or a citation is needed because we disagree that a paper standard even exists,
The link to the specification has been given twice already
https://www.opengroup.org/membership/forums/platform/unix it's not an Open Standard afaik, but it does absolutely exist
POSIX is technically not the single Unix specification, though the differences are mostly academic and legal
i didnt take that seriously. suppose that i make another page that was the unix standard is "everything linux"
what seems obvious is not always
A Unix-like (sometimes referred to as UN*X or *nix) operating system is one that behaves in a manner similar to a Unix system, although not necessarily conforming to or being certified to any version of the Single UNIX Specification. A Unix-like application is one that behaves like the corresponding Unix command or shell. Although there are gen...
I don't see why you wouldn't take it seriously. It's the requirements set out by the group that controls the UNIX name, on their site.
i will post my one again
its not on the same code path as UNIX as was the intended path of the founders
my citation seems clearer than the unix standars that is very vauge
yeh that was a history of conversation
I am sorry but a Wikipedia infographic is not a better argument than the open group saying that a Linux distribution was Unix certified.
On the page about unix
ok you guys win then
its a UNIX system
Maybe its me but i really cant sand discord anymore. its becoming exactly like stack abuse only with a thousand cuts
i bet you noone cares to ask why. i dare you 😉 lol
im going to bed so here is why ... you are selfish. you cant be in the middle. its why we have stupid wars. ridiculous race we are
I've read what I can of this linkable now and it's not very open to the public. You have to login to actually read a spec which who on this thread has tried to read read? That is exactly what I would expect from a corporate Unix. I bet Noone even cares about open source here but that is what Unix was trying to kill and it took effort to keep it open.
So this link does not openly present what Unix is and if you find some meaningful stuff on there then please let let us know what Unix really is.
Other than some corporate grift
Anyone using arch?
Discord just released a new update
And i downloaded .deb converted it into .pkg.tar.zst
And tried installing it
Now it is downloading "intel-oneapi-baskit-"?
And it is 2gb? What is going on
Fk I totally missed what happend above
"Corporate grift" is a very strongly way of wording it but... yeah, being able to advertise your OS as being UNIX is very much something very corporate and legal.
The Open Group are the organisation that hold the trademarks to the UNIX name, and so get absolute ultimate authority deciding what does and doesn't count as it. How do they do that? By having a standard laid out that you have to meet, and then going through their process and terms of certification.
It's a standard that is made up of a handful of other standards, but the main core of it is the POSIX standard, which is referred to on that page, and was also linked to you yesterday in chat: https://pubs.opengroup.org/onlinepubs/9699919799/
Most linux distributions don't bother going through all of the work of meeting the UNIX specification, but they usually aim to be all or mostly POSIX compliant - hence why many distros are then called Unix-like (or *nix, among other labels)
Unix has always been a corporate thing (as was just about all software for quite a while). At the height of its popularity, it was free for universities, but very much a commercial product for most users. Open source unixes were only really used by hobbyists, with production deployments using software vendors. Unix predates open source being all that popular (mostly predates the fsf), and the standards not being readable for free is very normal for standards (ISO C and C++ are also not free, though you can get drafts). Even unis used the commercial distros afaik, they just got them for free.
Yeh but I think we are just trying to understand what they actually claim is Unix complient. But I can't get that from that website because it wants me to login. So why they are not even freely disclosing that. Shirley you have read it if you have shared the link?
I honestly never really cared about what the standards actually say beyond a school project where we had to be unix compliant. it's more of a cool trivia thing than something worth investigating deeply. POSIX is freely available and it is like 99% the same thing as the SUS if you care to find out.
there is a bunch of trivia you can find, like -r vs -R for most commands, or c99 vs cc, but most of the time, you just care about linux, rather than some theoretical other unixes
OK then don't share links that have no valuable info in them if you are trying to bolster your view in a debate.
it tells you that opengroup considers these standards to define unix, it tells you that there is a linux distribution that is certified as a unix. What more do you need to know?
My question was what does it mean to be compliment not some fluff for corporate head that has no understanding if what it means.
in that case, the posix specs are what you want https://pubs.opengroup.org/onlinepubs/9699919799/
This is the standard the single unix specification refers to for the actual OS definition stuff. They are different names, since the standard body defining POSIX is not the one that owns the unix trademark
For example, here is the specification for the unix C compiler https://pubs.opengroup.org/onlinepubs/9699919799/. It will exist on macos, bsd, and most linux userspaces.
it is, there is a linux distro that is fully compliant with SUS, and thus with posix.
or well, linux itself is not an operating system, but with the proper (read most used in practice) userspace, it is a proper unix
Most are not posix complient though
GNU+Linux without some truly exotic configs would pass the certification
as they have done twice before
GNU does care about posix compliance to some degree, as does busybox et al.
Gotcha. Well tanks for the debate but linux can diverge quite easly from unix propper and has done and will do again. Some fringe cases may exist that stay in line exactly with what the corporate peeps want but everyone can and will move on if it makes sense.
I certainly don't expect my code or any c code to compile on Linux if it does on Unix os.
if you have 100% unix compliant C, it will compile
most useful programs do not get to do that, however
you generally need system-specific APIs, even if you have the unix standard backing you
Yeh and if we had to wait for Unix to say what we can do in the kernal then we are not getting anywhere. Many modify the kernal for different reasons and don't have to pay a toll to any Unix lawyer grifting off a century old patient. We really need to disconnect from the tm
Oh yes, absolutely, Unix is a relic and is not worth putting effort into, just make a good OS, not like anything short of BSDs will ever even interop, and BSDs are very good at running linux software by necessity.
An interesting example is that UNIX does not require TCP sockets to be supported.
The protocols supported by the system are implementation-defined.
https://pubs.opengroup.org/onlinepubs/009604599/functions/socket.html
but well, no one ever stopped making features for their OS because it wasn't part of UNIX. That's how the whole situation of many closed source mutually incompatible unixes happened.
welp, straight up can't reproduce my issue. It works perfect inside of docker
guess I'm using docker now XD
😊
I want to create a slideshows with say 20 pictures, and on each slide the picture is slightly different. It would make sense to draw the first picture and then describe each subsequent picture as a diff. (that way if I change the base structure in the 1 st image, I would automatically get the change in the next pictures.) this reminds me of
- git commits (since each commit describes a change) but it's describes the history of a file and not changes in a series of files
- Sprites moving on top of a background (as in a video game)
What would be some awesome tools to create such a slideshow? Last time, it took me 24 hours to create 30 minutes of presentation 😩🙏
Not sure, but LaTeX for the presentation and Tikz for the graphics. since, iirc, you can write Tikz functions, which would be ripe for modification down the line.
Thanks, I haven't userd tikz and only latex for my thesis.. I will take a look.
Might be more of a learning curve than you want, and I'm not entirely sure how you write a slideshow with LaTeX, but I believe it's possible
beamer 😄
Used to be a LaTeX package for that -- https://tex.stackexchange.com/a/693953
||```
% SLITEX VERSION 2.09 <25 March 1992>
% Copyright (C) 1992 by Leslie Lamport
eww, NSFW; do not click
Written by Lamport, eh? :)
Are there any python libraries for parsing the output of common unix commands like arp, ifconfig, uname, etc? I've had a hard time finding anything that's general or modern (found one library that can do some stuff from /proc but it's python 2 and not pip installable).
I'd hope you could get that same sort of information without having to run a subprocess at all
it'd be nice. or at least a separate tool that can parse it out into json
it's pretty reasonable to want to do something like ps | foo
parsing text is much less of a challenge than writing platform-independent code to interact with the OS
how would you make a new directory, put the contents of a different directory into it?
as in, just rename a directory?
yes
but
instead of putting the directories content into the new directory you create a file inside of that directory
and that file will receive the content
so directory a gets changed to directory b and the contents of directory a gets put inside of a new file named c inside of the newly made directory b
content of a directory… into a file?
yeah
so
like
the directory already has a file
you change the directory to a new one and you change the file to a new one pretty much
not sure I get what you mean
I don't see how the contents of s directory are put into a file
so
do you mean they're concatenated and written to that file?
and which part are you stuck on?
all parts
i made it inside of ubuntu terminal
but i have to make it inside of a bashscript
and i dont know how to do that
been racking my brain for a few hours for what its worth
so you were able to do the steps by manually running commands in a terminal, right?
then put those commands in a bash script
are you not using bash in your Ubuntu terminal?
no
its not the same
i have to make a script for it
not just write it out
yk?
Except for some things, you should be able to directly use what you type in a bash terminal prompt in a bash script…
What's the script you've written that's not working?
hey yall, could really use some help
I just installed linux in dual boot, but when I restart linux after the installation it's showing this screen
How to get to the desktop
log in?
Uh did you install a desktop environment?
Yes I login
No
Usually mint should come with cinnamon, weird it didn't go to a login manager
I installed this one
what DE did you use? cinnamon, kde, gnome?
Try cinnamon-session
They just showed what the y installed lol
any errors in journalctl?
Cinnamon
run sudo journalctl
Um I forgot
run df
Looks like I need to reinstall it correctly
Reinstalling might be easiest yeah
fastest may be to edit the /etc/fstab
Ok thanks
huh, that's a pretty weird problem
Might just need a reboot
in Ye Olden Days, linux would run "fsck" on a filesystem, and might bring it up read-only if there were errors
It still does. ;)
I use arch
Does anyone know how I can swap windows key with space key in Linux mint operation system
I broke my space key 💀
I am new to linux
Ok so first I need to install both packages
from the PPA, yes
that means that the people who maintain Mint haven't "packaged" interception-tools to work with apt
so you'll have to install it manually
Ok
No problem now, but take care to not printscreen any secrets, like keys/passwords. 🙂
(And always prefer to paste actual text rather than pictures)
Oh idk about that, thanks for telling
I like input-remapper, has a nice gui
Repo is https://github.com/sezanzeb/input-remapper
On mint you download this deb and sudo apt install ./thatfile.deb https://github.com/sezanzeb/input-remapper/releases/download/2.0.1/input-remapper-2.0.1.deb
no, the PPA is outside of Mint's control
they need to apt update is all
@lethal trail ^
Problem solve:)
I just created a .Xmodmap
Write keycode 133 = space
Then
Run command: xmod .Xmodmap
@shrewd stratus thanks for giving me your time
np
One day I'll find out what is the difference between unix and linux. Right after i find meaning of life
pass the 2nd file name to first bash script
what?
question
read VOORNAAM
read GEBOORTEDATUM
CUR_DATE=$(date +%D)
BIRTHDAY=$(date +%D --date=$2)
if [ "$BIRTHDAY" = "$CUR_DATE" ]
then
echo "Happy Birthday ${VOORNAAM}"
else
echo "Hello ${VOORNAAM}"
why does this not work
what is $2 here?
and what does doesn't work mean?
and why do you read GEBOORTEDATUM and then ignore that variable?
read VOORNAAM
read GEBOORTEDATUM
CUR_DATE=$(date +%D)
BIRTHDAY=$(date +%D --date=$GEBOORTEDATUM)
if [ "$BIRTHDAY" = "$CUR_DATE" ]
then
echo "Happy Birthday ${VOORNAAM}"
else
echo "Hello ${VOORNAAM}"
fi
# (echo fred; echo 2023-10-22) | bash ayoub.sh
# Happy Birthday fred
yes yes
i fucked it up g
hold on
read VOORNAAM
read GEBOORTEDATUM
CUR_DATE=$(date +%D)
if [ ${GEBOORTEDATUM} = "$CUR_DATE" ]
then
echo "Happy Birthday ${VOORNAAM}"
else
echo "Hello ${VOORNAAM}"
fi
this is the new code i wrote
but that still doesnt work
what are you typing when you run it?
i want to ask for your birthday and if it is your birthday today you'll get echo "Happy birthday..." else
mine works fwiw
you're using windows; that's your first problem
seriously, your text editor isn't designed to work with bash
it's putting "carriage returns" at the end of each line, which is dumb. Also, bash is dumb: it pukes when it sees those.
maybe try WSL, and use a Unix text editor?
💐
you can get a cloud-based Unix system for free, or very cheap
i already installed Ubuntu on my laptop but i lent it to my brother so i can't use it rn
are you using WSL?
and i don't want to also install it on my pc
nah
online bash shell
OnlineGDB is online IDE with bash shell. Quick and easy way to run bash script online.
you're using Cygwin?! 🤮
idk what that is
but
probably yeah
shits ass
does get the job done tho
ill have to endure until tommorow!
question tho
i have this exercise that i've been having trouble with for the past 2 weeks can u help me with it?
I don't know; you haven't asked the question yet
ive asked another guy for help and it did help but im still not sure how it fully works
what in the world is "inginious"? Is that important?
no
its a name of something that doesn't matter rn
just think of it as in "this website"
well that assignment seems pretty easy to me. Is there some specific part of it that you're having trouble with?
i know how to do it all i just don't know how to write it out
i don't know how to format it all i guess
i can tell you how to print something out but i don't know where to put it for example if that makes sense
no, it doesn't
do you have some code written already?
so
if so, what about it isn't working?
no i don't
ah
i don't know how to start it
hard to help if you've got nothing
of course, this is a python discord
yeah
is this a python question? if so, open a channel in #1035199133436354600 , so we can leave this channel for Unix-specific stuff
its not im using it as an example so u can understand whats wrong with my brain
I don't want to psychoanalyze you 🙂 I just want to help you fix your code. If you don't have any code, then ... maybe write some?
I can't 😭
okay so, if you want to print something out its simple, print("...")
if you want to use a loop you use, for i in ...
and if you need a list you do list = [....]
but now lets say you want to combine them all, well thats my issue i can't do that cause my brain can't wrap its head around it
I doubt I can help with that
hopefully you'll understand this
well, I understand that you're confused about the basics of programming. But I'm not good at teaching the basics.
that's what your class is for.
no its a teacher alright
then ... ask them
its a task i'm not allowed to ask questions
you need someone to physically sit next to you, and talk; discord isn't great for that
oh.
and yet here you are, asking questions.
funny how life works sometimes 🙂
we're not supposed to help with exams, so ... 🤷
exams?
this is not an exam lol
ill just ask questions on code ive already written and figure the rest out myself
for FILE in $(ls -a) what does -a do here besides show displaying hidden files ?
match command-line arguments to their help text
also man pages provide details about that
okay ill try that
You should get help in one of the off-topic channels. Read the topic of this channel, it isn't catered at explaining basic bash programming
im back
with code
filename=$(basename "$1")
VAK=$(echo "$filename" | awk -F_ '{print $3}')
TITEL_VANTAAK=$(echo "$filename" | awk -F '{print $4}')
mkdir -p "$VAK/$TITEL_VAN_TAAK"
Here is more code: if True: print("👍")
Do you know about man?
Hello everyone!
I'm using Ubuntu 22.04.3 LTS and have Python installed on it.
I do get Python 3.10.12 when I enter python3 --version in the terminal.
But when I run scripts that are located on my external HDD, it shows
/bin/sh: 1: python: not found
[Done] exited with code=127 in 0.045 seconds```
python != python3
type python3 instead of python
Yes, it worked!
Thank you @fickle granite
The thing is, I did run the script using Code Runner extension in VS code. How do I configure this to use python3 instead of python?
maybe it's in one of those JSON files under .vscode
Hey everyone
Wondering if there's somebody who knows how to extract content and put said content in a different directory? Do i use a variable?
You can use tail to see the most recent lines, like head shows just the initial lines
tail -f for following the… tail
hi
this is my code mkdir -p InleidingProgrammeren/Huistaak1-HelloWorld
tar -xzf assignment_UA_InleidingProgrammeren_Huistaak1-HelloWorld_2019-11-11.tgz -C InleidingProgrammeren/Huistaak1-HelloWorld --strip-components 1
but i was supposed to use regular expressions so i have to convert this into regular expressions but im not sure how?
Neither do I. What you've shown has no relationship to needing regular expressions
its not about needing it
the exercise my friend gave me is for regex
i can't hardcode it
Nothing there is going to use regex
im new to ubuntu and linux in general and coming from windows, i have this question:
is sudo apt update && sudo apt upgrade similar to windows update?
yep
although it will update your Ubuntu packages, as well as the operating system
thats neat
thank you
what is the stackoverflow equivalent for linux stuff?
Unix stackexchange
Or superuser (maybe)
thank you
tail is the newer messages - the ones at the end of the file
how do you exactly build from source in linux? i rarely succeed because most of the times the deps aren't available or "can't be installed"
im on ubuntu 22.04 LTS, if that matters.
is there an article/doc i can read about this?
i know that different application would have different deps, and therefore different steps, but is there something they all have in common?
it's a pain in the butt. I use pyenv, and they suggest dependencies to install: https://github.com/pyenv/pyenv/wiki#suggested-build-environment
I'm talking about building python from source, not arbitrary programs
the build-essential package is, well, essential 🙂
Maybe helpful if you haven't read it: https://help.ubuntu.com/community/CompilingEasyHowTo
thank you guys
the tip about apt-file is useful -- I use that a lot
i dont find a man entry for apt-file, what is it for?
it solves this problem:
You know you need a file named "bloviate"
You have no idea what package provides it -- there's no package with that name
So you type apt-file search bloviate and it says /usr/bin/bloviate: oration-utils or something, so then you do apt install oration-utils and there it is
ooh
it finds deps for us?
that's pretty cool
or rather the parent package where the file comes from
what are recommended lightweight browsers for ubuntu?
i've been using epiphany for the last 2 days, but looking at the cpu usage (it's probably not correlated since my cpu is not that fast) it's pretty resource hungry.
actually it's not really epiphany that is using a lot of cpu, its WebKit
lightweight browser? 🤣
those aren't really compatible things.
we are forced into ecosystem of using Chrome/Chromium, with trying to catch up Firefox + apple's smth
at least something that attempts to be lightweight.
should i use Lynx lmfao
it is bad idea using anything beyond Chrome/Chromium, Firefox and this apple's smth.
Because those browsers are original ones with their engines capable to parse/browse more than 99% of today's internet content
Anything else will not be able to parse it correctly, if uses any different engine (because it is... mindbreaking complexity)
or will be having unauthorized inclusions of smth else.
use pure Chromium or Firefox if u want most default linux friendly option
got it
so it's not really linux's fault, but big corpo's
yup. We have browser monopoly, with one of them trying to be the only one at any cost.
also another question
sometimes when I try sudo apt install <package> it doesn't found it and instead suggested me installing through snap
how many package managers (is this what they are called) exist for linux?
and which should i trust?
Ergh... ubuntu is usually using next options:
- snap, for installing up to date packages with autoupdate. Most laziest option useful for... some stuff u don't want to take care of at all.
- apt, has remote packages available too. It installs things frozen dedicated for your OS version, like ubuntu 22.04 for example.
- Useful to install most stable options. as downside they can be often out of date.
- useful for Docker as u prefer stable/frozen versions installing there
- apt with added new remote sources. Instructions like for Docker Engine usually have commands to link apt to their most latest version installation, and u get your
apt updateupdated to new remote packages. Then it has no downside regarding outdating, but instructions are a bit more lengthy usually. - sudo apt install ./package.deb. U can download and install in offline way any Debian package
- u can just download and install on your own already compiled binaries with little curl/wget and moving binary to any appropriate bin path. Useful for single file programs. Some the best programs are made like this.
- u can download source codes and compile them and install fully manually
may be there are other options/other managers but i dont know their usage for Ubuntu distro
i usually use Snap for long time desktop used stuff that has good Snap support.
Otherwise i fallback for apt for difficult things (like Docker). or for temporal stuff i fallback to remote apt or deb packages.
i like using curl/wget installed binaries too though
i still don't really understand how linux installs applications, most things i have installed are from apt and snap. i haven't really used docker so i don't really understand how that works.
.deb packages are like .exes so there's no problem there.
i still cannot comprehend how to build from source 😂
i read the manual on ubuntu from a link someone here gives, but as that is quite general (which helps), some applications are just so obscure
but i feel like if i know how to build from source, things are gonna be so much more flexible
also do i need an antivirus on ubuntu
seems like i don't need it
https://help.ubuntu.com/stable/ubuntu-help/net-antivirus.html.en?external_link=true
that's one less thing running on my slow laptop
i build from source only if developers were lazy in all criterias
- to make snap package
- to make apt remote available package
- and did not compile .deb package
- and did not provide even compiled binaries for downloading/installation
- and there is no even easy to install python pip/golang installable package
- thing i seek is not available as Docker image for downloading from Docker Hub/AWS docker registry
- this is my default for postgres/redis/mongo/nginx/apache and other web stuff
you know... i remember only one time some year ago when i needed compiling program from sources directly 😅 tried to use some obscure Git GUI.
p.s. that's actually a thing to remember. some common programs are just installable via pip/go/rust cargo stuff. Kind of yet another atlernate program managers
thankfully so far what i needed don't require me to build from source. i tried to with one browser app called midori, and when I was installing the deps, like 3 of them are not installable.
and that is where I often fail. tried installing the deps manually by myself through apt doesn't work, aptitude says the same, etc.
yea the pip one is pretty sick
i can install and use things from the PyPi index
if smth is not installable, may be it is just shit that is not your fault that it is not installable.
otherwise i use docker containers and virtual machines to experiment with dangerous fragile installs
fair
i should learn to use docker
at least try to use it with my python projects first before doing things with my linux install
@gilded cove valid if u use Stable Long Term supported common distro. i use KUbuntu 22.04 LTS. which got aged long enough for all programs to catch up and support
if u use some snowflake unique distro in experimental/newest versions, then it is your own fault 😊
me too, i use 22.04 lts since that's what people here suggested
i was also thinking about using the "beginner-friendly" distros, but idk if it's worth it for me to not just use a distro that has already been widely adopted
relatively to, other linux distros of course
Definitely recommending. Best for web ecosystem
everything from web becomes available to be run without installation
just docker run stuff (it will pull stuff from remote docker registry automatically)
ooh
i'll look around for that
lmao "docker captain"
also aint that kubernetes logo
nope. that's docker logo. Kuber has... ship steering wheel as logo
the O of "Poulton"
ergh. he has book The Kubernetes too. which is updated yearly.
and docker and kuber are veeeeery connected
fair
kuber essentially is running docker built images
container scheduling and lifecycle regulating multi server system 😊
i have a .py file that i want to run by double clicking. this file already has the subprocess stuff to allow it to be double-clicked. however it just opens the pyfile in gedit.
the deps are inside .venv which has to be used to run it in a virtual environment:
from subprocess import run
from pathlib import Path
from sys import platform
PROJ_DIR = Path(__file__).parents[0]
python = PROJ_DIR.joinpath(".venv", "bin", "python3")
if platform == "win32":
python = PROJ_DIR.joinpath(".venv", "Scripts", "python.exe")
app = PROJ_DIR.joinpath("src", "read_temps.py")
run([python, app])
how do i do it in linux?
The recommended way to get the current Python executable program is with sys.executable
Oh you need to use the venv's executable, right
Activating the virtual environment will change your shell’s prompt to show what virtual environment you’re using, and modify the environment so that running
pythonwill get you that particular version and installation of Python.
So you need to run three commands in one subprocess:
- activate the venv (platform dependent)
- run
pythonon the venv's main program file - deactivate the venv
u can simplify procedure by running venv/bin/python3 main_program_file/or_module
activating deactivating is not necessary if u just point path to venved python
Activating a venv is an alternative to specifying the interpreter path yourself
Correct
I've just read that in https://docs.python.org/3/library/venv.html#how-venvs-work
I like how the tutorial says
Once you’ve created a virtual environment, you may activate it.
but not that it's unnecessary to run a program in it
will do
thanks!
@gilded cove
As explained there, you need to check for:
POSIX:
- bash/zsh:
$ source <venv>/bin/activate - fish:
$ source <venv>/bin/activate.fish - csh/tcsh:
$ source <venv>/bin/activate.csh - PowerShell:
$ <venv>/bin/Activate.ps1
Windows: - cmd.exe:
C:\> <venv>\Scripts\activate.bat - PowerShell:
PS C:\> <venv>\Scripts\Activate.ps1
Ah, my bad again, those are activation scripts
The path to the Python executable program for venvs is <venv>/bin/python for POSIX and <venv>\Scripts\python for Windows it seems
i believe already have all this setup, my issue is that, if i double click the file, it opens .py file in gedit text editor instead of actually running the program
@gilded cove yeah read this
Use those as python
python = PROJ_DIR.joinpath(".venv", "bin", "python3") i have, with this line
my venv is inside the project folder, not in user though
My bad. Rereading this seems like you don't have any issue regarding being cross platform
So you should be good to go with that
The documentations don't cover Linux specifically, so it's probably like POSIX
in the end i resorted to creating a simple bashscirpt that runs this file lol
not a double click, but whatever
If running the program using the venv's executable launcher opened it in gedit, you need to report that as a bug, but I suspect you simply aren't doing that to begin with
I mean I see the code
But I can't believe my eyes
i am double-clicking that file, and yea gedit oepns
That's not the problem I thought you were having
Open the file with the venv's executable
i did chmod u+x <thefile.py>, in the context menu Run as a program.. pops up, and every time i try it it just closes straight away. it's a behaviour i have seen before and i can probably figure it out
Double clicking has a different file association it seems. Regardless, running a project which should be run in a virtual environment by double clicking the main program file isn't guaranteed to run it in its intended virtual environment
Rest assured, this Python program will work on Linux if the directory tree (.venv and src are under PROJ_DIR) is the same
I don't know how to change file associations on Linux, but that isn't a problem with your Python snippet
i don't either
i literally just switched to ubuntu 2 days ago, still getting used to it
the only thing i have setup is my python dev stuff kek
this depends on your file picker, nautilus will only run when the file is set to be run as a program in the file properties pane,
so give it execute permissions, then look for file manager specific shit
oh
well that sounds like its running but crashing
so run it in a terminal
also you will prolly want a shebang at the top if you want it to run as a script
you have to tell the system what interpreter your script should be run from
Hey guys! HackerSploit here back again with another video, in this series we will be looking at how to create shell scripts.
A shell script is a computer program designed to be run by the Unix shell, a command-line interpreter. The various dialects of shell scripts are considered to be scripting languages
⭐Help Support HackerSploit by using the...
so just change it from the path to bash to the path to the python interpreter binary you wish to use
otherwise the system may be doing something like: "running your python script with the bash interpreter"
I did try running it in pycharm, through the terminal and the bashscript o made and they all ran. So idk what's wrong
i was looking for tutorials on how to install ffmpeg, i was going to try to build from source but some deps are unavailable from apt so i just gave that method up.
i landed on a page that says "add the universe repository to your linux and install ffmpeg from there.". a bit of reading reveals that ubuntu has 4 main repositories namely main, universe, restricted, and multiverse.
kinda weird how I didn't get notified by atleast ubuntu itself of the existence of these 4 main repositories kek
huh it's all in software & updates
well that's my bad i guess
maybe now my problems with uninstallable deps can be resolved since i just added the universe repo
is ffmpeg itself not in the ubuntu repos?
https://launchpad.net/ubuntu/+source/ffmpeg it's right here @gilded cove
(other repos for other distros are linked on the homepage https://ffmpeg.org/download.html)
ffmpeg is in the repos, yes
though actually, question of my own: is there a way to get latest ffmpeg from the ubuntu repos if I'm not on mantic ubuntu? the last available version in the repos for my ubuntu release (linux mint, so ubuntu jammy) is old.
There were uninstallable deps with one from the main *repo
i tried it with apt and it didn't find it. not before adding universe into the list of repo.
im on 22.04LTS if it matters
"Latest version of x" and "ubuntu" usually don't mix lol
Snap might be more up-to-date tho
no snaps on Mint, though I could allow it in theory
different question then: if I want to stop using the ffmpeg package and instead install ffmpeg manually from the binaries, what do I do with fact that some packages depend on it?
keep it installed but use the other one via its absolute path?
Or use some sort of environment manager
You just remove /etc/apt/preferences.d/nosnap.pref
i'm aware, i mean that I don't want to allow snaps.
I ended up just adding it to path in .bashrc, so, yeah.
seems like i have been running ubuntu with secureboot off 💀
idk what that implies but mokutil says i was in setup mode
It doesn’t really mean much or make a difference
I see
I needed it to install linux amd graphics
Its fun when you're trying to install drivers and it errors out, and turns out I tried to install 20.04 drivers on 22.04
i can't read apparently
one of the main reason switching to linux is to finally get away from incessant 'update to the latest version' nagging
what happens to a linux distory when it is no longer supported? for example im on ubuntu 'jammy' and it is supported up to 2032. what happens after that?
I've recently decided to start off with Linux. For this, I am going to intall Ubuntu. However, 23.10. as the latest version or 22.04.03 LTS as the previous version?
LTS is the long term support release, it's supported untill june 2027, while 23.10 is only supported untill july 2024
It's a choice between newer packages and longer support.
Is it just the fact that LTS is support for a longer period or aren't there any benefits of updating to the latest version?
Most professional use is on LTS
I heard of Ubuntu 24.X LTS coming 2024. Wouldn't it make sense to update then?
What is your goal?
Is it really that goal-dependet? I'm a freshman studying CS, learning Linux would be interesting, I thought.
There are a lot of different distributions.
But wether you want to use more up to date packages, or the LTS release that's something you'll have to decide for yourself here, there's arguments for both.
Will you be updating to 24.X LTS as soon as it is released?
I'm not using ubuntu myself, I'm using a rolling release distribution that doesn't have versions.
But ubuntu is a good place to start, and switching to the next lts once it comes out seems like a good idea if you want to get more familiar with it.
That sounds quite technical...
It just means that it's constantly updating\
Alright, it was a nice chat with someone from the Moderation Team. Have a good one! 👍
That doesn't mean I'm actually knowledgable at things though 😅
you just stop getting updates, and eventually it's possible that you can't use some third party programs as their dependencies go out of date
if you want long term stability, use upstream debian imo
or red hat or suse, being backed by companies that primarily serve "enterprise" clients
freebsd seems pretty stable too but i haven't used it much
that doesn't sound too bad, i can always wait to update at the right time it seems.
debian seems to be for professionals, I don't think i need that much stability any time soon.
also can i just say tty is a blessing
i f'd up something earlier in the day and it only took me under half hour to fix and get back to a working boot
i wouldn't say it's for "professionals", it was originally more or less someone's hobby project and generally nowadays tries to serve a wide variety of needs. but it's true that it tends to require more tinkering for typical "graphical desktop" usage. ubuntu tends to include more drivers and focus specifically on desktop users
and yes, if you're tinkering with your system at all, knowing how to get around in a purely text console environment is essential
i see
i believe ubuntu is still the best choice for me, for now.
yeah im still getting used to it. and since its basically bash but in pure text console makes it easier to learn
i personally do not like ubuntu at all (snaps suck, they tend to customize things so you end up having to deal with a lot of ubuntu specifics, and they do some really weird things with how they pull in upstream debian packages) -- but it works for a huge number of people and it's hard to argue with that
it literally is bash actually. the box that shows you the text is a completely separate program from the one that actually reads your commands and emits the output
yeah i just like that it just works, if that make sense.
aaah
the linux console is a variety of terminal aka terminal emulator
what desktop environment are you using?
im on ubuntu jammy
i assume that's using GNOME?
yeah, so there's a program called GNOME Terminal or something like that
that's also a terminal, it's in the name
im probably using that right now
i haven't really customized anything on this distro
GNOME Terminal, KDE Konsole, urxvt, etc etc all are "terminals"
i see
they basically just relay text back and forth between your user interface / keyboard and other programs
usually when you open a terminal, the program you see is called a shell
there's gnome-shell in my processes so im probably on gnome terminal
Bash is a shell
i believe gnome-shell is actually what runs your graphical desktop
oooh
i see
that's also a "shell", albeit a different kind. very broadly, a shell is any program that allows you to interact with your operating system. think of it like a shell on a seed or a nut. inside is the "kernel" -- the inside parts of the operating system. users usually don't want to interact with that directly, so they are provided with some form of a shell around that kernel.
usually when technical people say "shell" without further qualification, they mean a text-based shell like Bash
and often they'll say "graphical shell" to mean something like GNOME Shell or the Windows shell
hopefully that gives you a clearer sense of what you're working with
oh wow, never correlated shell and kernel before
What is the “GNOME Shell”, then?
uhh why is the driver i installed yesterday doing this
im doing nothing at all
is it compiling something
sure looks like it
i did run apt update
I don't *think * apt update builds stuff from source
trace the "ancestry" of those processes -- i.e., find the parent of 55519, and its parent, &c
which is weird
was trying to install flatpak and got a message that something it needs is being held back by unattended upgr
so it's probably that
that's a bit too deep in the Ubuntu weeds for me 😐
unattended upgrades is a service that runs every so often to keep your computer with up-to-date packages. That CPU usage is probably from one of those upgrades. The compilation is from building the drivers (see: dkms).
i see
so my assumption was on the dot
but why so suddenly tho
i appreciate unattended driver installs, but dang that almost prompted me to reboot my machine because i assume something was glitching out
I have a problem with my terminal in Ubuntu - I cannot start it!
can you provide more context please?
some error, or maybe a screenshot or even a photo of your screen
The normal way to open the terminal is by double clicking at the icon or using the command Ctrl+Alt+T, however none of these methods work!
try rebooting.
if you already did that, then you can try this:
press alt + f2
type in gnome-terminal and press enter
if this doesnt work either, you can use the tty console
I did gnome-terminal just 5 minutes ago. Nothing happened!
you can download another terminal emulator... maybe in ubuntu software there is one
such as terminator or xterm
What about TTY console?
you could press ctrl+alt+f2 to enter your tty CLI... to go back to graphical you press ctrl+alt+f1
I cannot even see my password when typing. Is that a normal behavior in Linux?
positive.
Alright, let me just try that...
you can run sudo apt-get -y install xterm
this will install xterm, another terminal emulator
then go back to graphical (ctrl+alt+f1)
press alt+f2 and type in xterm
Is there a way to copy + paste commands into the console?
It says "{my_username} is not in the sudoers file. This incident will be reported"
huh. is this your personal PC?
oh wait you can enter tty from the gui desktop
TIL
Yes
That's normal for a fresh install. You should log in as root and add yourself to the sudoers file
it it really? on ubuntu? 🤔
Yes, it is
It says: "84 updates can be applied immediately. 60 of these updates are standard security updates."
Not sure...I would have expected Ubuntu to sort that out in the installation setup
Ubuntu generally puts the first user into the sudoers file.
It's not even been 24 hours since I can call myself as a Ubuntu user. That all seems too complicated all at once
i installed ubuntu 3 days ago and i don't think i had the problem you have right now
are you on jammy as well?
don't give up :)
we've all been there, believe me
https://wiki.archlinux.org/title/Sudo talks about how to updagte the sudoers file
(The Arch wiki is a great resource, even if you're not using Arch! Just ignore anything to do with pacman - the Ubuntu equivalent is apt, but the syntax is different)
I've only downloaded: VirtualBox 7.0.12 + Ubuntu 22.04.03
This sounds like you installed from a rather old installation medium.
What does that mean? I did what I was supposed to do, I guess? 😬
It's not a big issue, I'm just surprised that there are that many updates for a newly installed system. I'd have expected a newly downloaded installer to have less...but tbf, I'm sure I've had the same in the past.
the weird thing is that your user doesn't have sudo permissions out of the box
Unless you added the user later
did you install ubuntu from scratch? or you downloaded a VB image?
I clicked on Download
the username you specified during the installation of ubuntu is the same you're using right now?
Virtualbox
Yes, {my_username}_vm
what do you mean by {my_username}_vm?
in the tty, you could run su root
and try to put in your password...
my username is "puvude_vm"
What are the next steps I should take?
you can try this
is there a user named puvude?
Now it says: root@ubuntu-vm:/home/puvude_vm#
nice =)
now you have full access...
but remember, with great power comes great responsibility
you can now follow this guide
to include your user puvude_vm in the sudoers file
Uncle Ben... 😄
then you can use sudo normally
What would be the next ideal command to type? I guess it's sudo apt install xterm
If you're still logged in as root, you don't need the sudo; just apt install xterm
I did, it's finished now
Then I'd recommend adding your account to the sudoers file, as to make this easier in the future.
Okay, what is the command for that?
- Open the sudoers file like this:
EDITOR=nano visudo
- Add a new line at the end, exactly like this:
puvude_vm ALL=(ALL:ALL) ALL
- Save the file by pressing Ctrl+O, and then enter
- Quit with Ctrl+X.
Can I now leave the TTY for that?
First do this in the TTY, after you're done with it you can leave it.
I've typed the exact same command again EDITOR=nano visudo: it has saved my changes
Great
Then you should be able to go back to the normal GUI mode, and try to open xterm there
It says "Save modified buffer? Y: Yes, N: No, but I cannot type Y for Yes
What do you mean by "cannot type y"?
I've got it fixed
Yes, xterm has finally opened itself 👍
🎉
Will I never be able to open Terminal?
Is the command sudo apt install gnome-terminal?
Yes
It says that gnome-terminal is already the newest version (3.44.0-1ubuntu1)
Yeah, that's both strange (why can't you start it then) and not strange (it should come pre-installed)
What if you start it with the same method you use for starting xterm?
So what do I have to do about it?
Whenever I click on the icon of Terminal, it loads on the left upper corner (next to Activites) for about 3-5 seconds and then disappears without opening the application.
You can at least pin xterm to the sidebar thing, and remove Terminal from it
If you do alt + f2 and type gnome-terminal, does it work?
It does not work, it does not open
I have another idea: Start xterm and run gnome-terminal from there. Then you might see an error message that could help us further.
you might try sudo apt remove gnome-terminal
then sudo apt install gnome-terminal
to reinstall... maybe it works
I wonder if the initial installation process was somehow not completed - that might explain the two oddities - not having sudo access, and not being able to launch terminal
There is an error I see
yeah. very strange
How to copy text from xterm?
Ctrl+Shift+C
Error constructing proxy for org.gnome.Terminal:/org/gnome/Terminal/Factory0: Error calling StartServiceByName for org.gnome.Terminal: Timeout was reached
Google tells me that's a problem with your locales... it really seems like the installation somehow didn't finish..
Isn't there a way to completely reboot the system as a whole?
you can delete your VM and reinstall on a new one
You mean I can remove/reinstall that?
yes
It took me about 30 minutes to install?
I have reinstalled ubuntu countless times lol
it happens
You know what? Let's give it a try!
that's the spirit :D
With
The guest additions allows you to use the clipboard between the host and the guest (among other things)
What about the checkbox?
Either way - that just decides whether you can use an EFI partition or just GPT (iirc). I would enable it, personally. But the installer should handle either way
Is that necessary for me?
They're just two different ways to organise your disk - the EFI is the more modern form, but it won't make much of a difference for your VM install
Is there any disadvantage?
What about this?
Give it enough for the system and your user area, at least. I'd want at least 100GB, but that will also depend on how much of your host system's hard drive you can afford to use
What about Pre-allocate Full Size?
I generally do. If you don't pre-allocate, it will grow dynamically, which can cause issues if you fill your host's hard drive and don't leave enough space for the dynamic allocation to happen in the VM later on
So it's recommended to turn it on?
I would, yes
I removed my Ubuntu and reinstalled everything: Conclusion: Terminal does not open
still doesn't open?
That's odd.
As if someone would have hacked my machine or something...
my man, I think your download got corrupted smh.
😭
ubuntu-22.04.3-desktop-amd64.iso
What is the hash?
a hash is function that calculates a unique integer for some data.
and it should be the same every time.
it's like a fingerprint of your file.
What is the solution to all these problems I somehow have?
Each ISO has it's hash. You can check on the ubuntu mirrors:
it's the sha256sums there
you can redownload the ISO and try again.
or if you just want ubuntu working you can use a already preinstalled imagel
Wouldn't I lose storage on my machine?
you just remove the old one
or you could use something like OSBoxes that provides a already installed virtualbox image:
https://www.osboxes.org/ubuntu/
Download Ubuntu Vmware (VMDK, VHD) and VirtualBox (VDI) ready-to-use images for free. Run Ubuntu as secondary OS on your primary operating system.
I'm currently reinstalling ISO. What is the alternative, in case it does not work again?
What's your goal for installing Ubuntu?
Well, I'm a freshman studying CS, who wanted to explore the world of computers. Isn't that obvious?
How long did the installation process (after setting the configuration) take on average?
30min sounds about right
Mine's just finished installing; I started it about 20-odd minutes ago
What I just did is installing the same ISO again, so ...(1).iso and setting all the configurations as usual. Let's hope, it will work out this time
gnome-terminal started for me from ctrl-alt-t
My user is not in the sudoers file, though, so that might be normal
maybe they changed this behavior in 22.03? which is a weird choice tbh
although I think Debian is like this
and gnome-terminal should always open, yeah
often the default sudo config includes a group like admin or wheel or sudo but not any specific users
yeah. but I have never seen this behavior in ubuntu desktop specifically
I have not yet used the 2023 version though
I've got something to say: It does not work
However, I've watched a youtube video, where they told about the same problem. You need to change the language once and restart it. After logging in, the Terminal should open as intended...
wow, such a trouble to get the default terminal emulator to work...
huge L
I've wasted so much lifetime, I could be more productive
I don't consider it a waste of time.
You have learned much and did many things you never did before
;)
that's learning
linux is like that, and working as a sysadmin I assure you, it could be much worse lol
I recommend you to try out other terminal emulators too, besides gnome-terminal...
I personally use terminator, but there are so many others.
but in the end of the day you just need a black screen to access your shell
I thank anyone, who followed along my path solving the problem 👍
is the terminal problem related to them installing it inside a vbox?
KDE Konsole is the best terminal emulator. Themes, tabs, split windows, monitoring for activity/silence ... what can’t you do?
It has a dependency on Qt for theming and other dependencies that need to be pulled (parts of KDE and some other misc libs). Otherwise, it is quite a featureful terminal emulator.
Terminator is kind of sick too
i prefer to use Konsole due to being nice default though
I don’t mind that. It’s just an apt-get install away. If you really want to get into something exotic, how about Cool Retro Term?
@green tinsel so why it bad
aaah
and the OSS community generally doesn't like that
my laptop's already slow so what's another year of waiting
anyway
you were asking about how to install vbox on ubuntu
turns out there's an apt pkg for that
sudo apt install virtualbox
thank youu
i shoulda apt-cache search beofer asking
Using qemu+libvirt+virtual machine manager gui is pretty good for virtual machines imo
I believe qemu/kvm is more performant
@dusty willow What do you need help with?
What does the crontab configuration file look like?
Here's a generator for cron expressions:
An easy to use editor for crontab schedules.
Typically they look like this:
* 2 0 * 4 /root/backup.sh
Nice! So is it a file and I write the scheduling command with same format like this in it?
Yeah you can run this command to edit the crontab config:
crontab -e
then put in your config and save it
Nice.
run:
crontab –l
To confirm that it worked
hi y'all
for those on Windows machines who write python scripts
do you link your developer enviro to your WSL/Ubuntu python install?
do you uninstall python from windows?
plotting directly inside/into the terminal, anyone got something dumb-simple? Like bargraph with ascii, for example
kitty is v good, fast rendering is a must for me because i do most of my work in a terminal text editor and when they are slow then scrolling documents can really drag
@silk herald I ended up using wezterm, that way I can use the same terminal in windows if I need to. Is there any high level objective comparison between the "best"/popular terminals?
I used kitty for a good while too.
But it is too opinionated to me xP
The main problem is, I ssh into many legacy systems. So the TERM xterm-kitty doesn't function properly
oh, and u can't stop kitty from setting that envvar?
I do work on my workstation 99% of the time. I'm thankful. 👼
Never installed it in the first place... WSL is the only way to go
Which IDE do you use
I used to work on a Windows laptop for half a year, when I did I used Windows only for the browser, and for starting WSL. Everything else was done inside WSL.
If I'm working remote from my windows laptop, I just start wezterm and ssh to my Linux machine. (I use neovim as my editor)
How so? I didn't have to look at images, only code
Any data vis or graphical output of any sort?
Not really, no. There were some web services, but IIRC I could use those from the browser in Windows-land
It’s driving me nuts that there is no unified approach to how windows users overcome this problem. I think the short answer is they don’t, they give up and buy a mac
Or just replace windows with Ubuntu as their primary OS
vscode is available on windows, I guess a lot of people use that
VSCode also has a remote access addon that allows you to work in WSL, I believe. So, just like using it to access an ssh server, you can run VSCode on Windows, but actually be writing code on your WSL instance. (You can probably run an xserver and run Codium on the WSL and display it on the Windows via an X Server. I had various success with that in WSL1; WSL2 was supposed to be better at that)
ah what do you use?
ah cool
ummmmm, not that ive heard of,
I just get hints now and again
kitty is good for me and it can render images v well
alacritty was a little more janky but still good
vte based terminals ( like gnome terminal) should be getting better rendering soon
the kde terminal is good if you dont mind the gui at the top
foot terminal is pretty good
as for shells, it doesnt work well as a system shell, but nushell is really nice for day to day use, the key concept is that it replaces the strings passed through pipes with custom types
you can always read those half robotic autogen comparison articles but they are shit, just hearing different perspectives over time is probably the best
I think you see right, thanks for your insight.
I'm using wezterm, but I'm a bit worried because it's mainly a 1 person project and the number of issues is growing. It's working well for me now at least! 🙂
And it was the first open source project I donated to 🙂
It does, but then what if your output from your program is an image or data visualization?
Do you have to save it and view it through windows? What if it is an html file?
Err
HTML based image
ah maybe the best thing for it would be to ensure it works on wayland and to distribute it in an environment where dependencies can be locked at their current state somewhat, maybe flatpak, nix, guix or static libs
ig a lot of projects have little staff, ig it depends how often they work on it
and what their economic situation is
bye
You serve it from WSL and display in in Windows, like Lev said. Or you run the webbrowser via the XServer
terminator
It is just like using VSCode to SSH into a remote server, so you can view images simply by opening the file. Similarly, you can preview certain files (e.g. Markdown, Jupyter Notebooks) via the usual extensions
Personally, I have not noticed any difference in my VSCode experience between accessing a remote server and WSL
Back when only WSL1 was available, I had difficulty making my GPU available to ML libraries. However, this problem seems to have vanished with the introduction of WSL2
This sounds like you’re saying files can be viewed within VSCode, is that what you mean?
yes
I don’t understand. I only use VScode to write Python. I never look at files or directories in it
How do you write Python in VSCode without seeing what file it's being written to? :)
...or start a project without specifying what directory it's in?
You can open a folder/directory in VSCode as shown here
If you didn't know before, now you do xD
On Windows I'm generally using VS Code
Emacs a bit too but the GUI when launching from WSL is a little glitchy and annoying
just for testing lil scripting snippets?
you can probably wrap vscode in a script that will make files in /tmp
otherwise, i like to use ipython interpreter,
then i can use a nice prompt with highlighting and autocomplete
and if you press f2 then it opens the current entry in the editor defined with the env var $EDITOR, then you can run that
I think you missed my meaning here. I was suggesting that it's difficult to not see files and directories in VSCode (without, as I think you're suggesting, going out of your way to do so). Perhaps it's easier not to see directories, but it does expect you to create a file for your script to be run - and perhaps overkill if you're not doing that.
yeah well if it is just about not seeing the sidebar then that can be hidden,
if it is about running a script without saving a file then i would either wrap it in a script or use ipython instead
scripts are designed to be written roughly at the time of initial use
if guis ever get as good as scripts at being able to perform complex behaviour at a whim, then they will just begin to resemble scripts
It was a disbelief in this statement that gave rise to mine.
oh yep, didnt get the context
Hello, I see an interesting command in a conversation. It's :()(:);:. When I execute it on my phone, I got this. Can somebody explains it to me what it means
Simple explanation: That’s a function that calls itself. It keeps calling itself, but then the system ran out of memory and it couldn’t call itself anymore.
See above :)
But how it defines a function here
That’s a pretty malicious command and it would have exhausted your computer memory had you ran that command on bare metal, potentially locking up your computer for a while
:()(command); defines a function called : which will execute command in a subshell (i.e. it will spawn a new bash process and run the command there)
Okay, thanks 👍
This hopefully serves as an example of why you should not run random commands you find on the internet 🙂
Ah, I will be more careful next time
On settings on Windows Terminal, I've got two versions of Ubuntu. One is 22.04.03 with the Ubuntu icon and one is 22.04. with the Linux icon. What does that mean exactly? Should I delete one?
I know 22.04.03 is the current LTS
22.04, is idk
It looks like this
Tux is a penguin character and the official brand character of the Linux kernel. Originally created as an entry to a Linux logo competition, Tux is the most commonly used icon for Linux, although different Linux distributions depict Tux in various styles. The character is used in many other Linux programs and as a general symbol of Linux.
Why do I have two versions? Should I deinstall one of them?
i dont know why you have something installed on your computer
thats probally a question that you should be able to answer
I've installed Ubuntu 22.04. After that I have updated the versions, so that I now have 22.04.03. Has the older version become superfluous now?
maybe, i dont use wsl so im not sure why would updating install a new one and leave the old version
you can see all available versions with
wsl --list --verbose
Unfortunately, I get this:
That command should go into your PowerShell (probably as admin). Sorry for not being specific.
I feel like there is something broken
Was meinst du? Soll das so aussehen? 😏
nein speak German XD
On settings on Windows Terminal, I've got two versions of Ubuntu. One is 22.04.03 with the Ubuntu icon and one is 22.04. with the Linux icon. What does that mean exactly? Should I delete one?
use the --verbose flag as well please
Well, if you're not sure, I'd avoid deleting either of them. Maybe your WSL instance has been updated to 22.04.3, but the image hasn't.
It looks like this. I do not know what Azure Cloud Shell is used for
Azure is MS's cloud computing service. It may come preinstalled, like any other MS crap
Do you use it? Is it recommendable?
I don´t know if they have a free tier, and have not used azure that much personally.
AWS has a free tier for a year, if you want to learn cloud
Do you recommend anything else I should get for WSl 2?
I think ubuntu is enough
If you want to learn docker you could try out docker desktop... Although my experience with it on windows was pretty terrible lol
I heard that Docker is useful in terms of reliability between users.
docker is amazing. have you used github codespaces?
No. What is that?
github has a feature that you can deploy a container (it's free for a limited amount of hours/month) to run the code in your repo
and it has a VS code instance builtin so you can connect directly your VS Code to the codespace
however it can be a bit tricky to configure if you don't know what you're doing
Is it some sort of directory that is being saved in Docker, so the codespace?
do you know git/github?
Yes
so they use a JSON config to build a container ready to run your app. it all resides in your git repository.
in practice, yes, the docker container deployed will have a directory with all your code
there are some templates for python, react and other stuff
you can access the container's terminal freely as well
pretty neat
But I can do all of that by just downloading Docker and configuring it by myself, right?
yes you can... but on windows it's weird
docker desktop for windows uses WSL to instantiate your containers
it should work though
if your VM is still working, I'd recommend that you install docker on it to play around instead
Is my VM = Ubuntu?
I'm kind of confused right now! Your mean my Ubuntu-shell?