« first day (2114 days earlier)      last day (2844 days later) » 

@JacobVlijm let's do this here instead of in the comments
$ cat file
This
is,
are,
a,
a longer,  harder,  faster line
$ python3 -c "[print( (',').join([s for s in l.split(',') if not s == ''])+',') for l in open('file').read().splitlines()]"
This,
is, ,
are, ,
a, ,
a longer,  harder,  faster line,
 
@terdon What's the purpose of that?
 
@terdon I cannot reproduce it, see my example in the answer. It would also surprise me, looking at the code. What are you running it on? — Jacob Vlijm 2 mins ago
 
@RPiAwesomeness That new Skype looks like one I have on Win 10 - will it also have that sh...load of ads displayed all the time?
 
3:17 PM
@ByteCommander No idea
I've switched to Discord for basically everything anyways sooo :P
 
@terdon I get this (correct) output:
 
@terdon sure, remove the comments?
 
This,
is,
are,
a,
a longer,  harder,  faster line,
 
@JacobVlijm Done
@ByteCommander Really? Weird.
$ python --version
Python 3.5.2
 
@ByteCommander @terdon same here.
Python 3.5.1+
 
3:21 PM
Also 3.5.1+
 
...Not sure what the + is
@terdon looking at the code, it is weird. the split delimiter is never included
 
Any trailing whitespace?
$ od -c file
0000000   T   h   i   s  \n   i   s   ,      \n   a   r   e   ,      \n
0000020   a   ,      \n   a       l   o   n   g   e   r   ,           h
0000040   a   r   d   e   r   ,           f   a   s   t   e   r       l
0000060   i   n   e  \n
 
Question on slow boot: askubuntu.com/q/795169/417607
any ideas?
 
nope, checked before, when you mentioned
 
3:22 PM
@JacobVlijm yeap, mine does. That's the problem. Must have copied it from the OP
It works as expected if I remove it.
 
AHA
 
I must have added it at some point because my sed/perl etc solutions also fail with the whitespace and they worked when I first tested.
Oh well. \
Here, have a +1
 
@terdon then I am happy with the white spaces :)
@terdon remove the comments on my answer as well?
@terdon Thanks, he you also upvoted yourself! (kidding)
 
@JacobVlijm Btw why are you proposing such a complicated command?
What about this one:
print(*[line.rstrip(",\n") for line in open("fileee")], sep=",\n", end=",\n")
 
@ByteCommander note that the line can have mutliple commas at the end.
 
3:30 PM
@JacobVlijm Works perfectly.
bytecommander@BC-AlkaliMetal:~$ cat fileee
This
is,
are, were,,,,
a,
a longer,  harder,  faster line
bytecommander@BC-AlkaliMetal:~$ python3 -c 'print(*[line.rstrip(",\n") for line in open("fileee")], sep=",\n", end=",\n")'
This,
is,
are, were,
a,
a longer,  harder,  faster line,
 
@ByteCommander The answer is very complicated the second you start using python or perl for such simple tasks :)
 
I agree that sed is the preferable tool here, but Python can do this job as well in pretty simple ways.
 
@ByteCommander it depends on the situation, it seems
...And yours works fine too, but didn't test it on big files.
 
Mine should be faster and especially consume less memory.
 
@ByteCommander Sure. So can objective C.
 
3:37 PM
I don't understand why you are reading the whole file into a list at first...
@terdon Let's post a solution in Brainfuck.
 
:)
 
@ByteCommander yup, yours is faster, on bigger files, while mine is faster on files up to 3mb. Not surprising, reading the whole file is faster on smaller files, per line has the advantage on big files. sed is the absolute winner on small files though.
 
    $ ls -lh newfile
    -rw-r--r-- 1 terdon terdon 14M Jul 13 17:49 newfile
    $ time python3 -c "[print( (',').join([s for s in l.split(',') if not s == ''])+',') for l in open('newfile').read().splitlines()]" > /dev/null

    real	0m0.310s
    user	0m0.293s
    sys	0m0.013s
$ time perl -lne 'printf join ",", (grep {$_ ne ""}split(/,/) ); print ","' newfile > /dev/null

real	0m0.171s
user	0m0.170s
sys	0m0.000s
$ time python3 -c "[print( (',').join([s for s in l.split(',') if not s == ''])+',') for l in open('newfile').read().splitlines()]" > /dev/null
And Perl wins. Again.
:P
 
@terdon OK, need to speed up my Perl lessons :)
 
The reason sed is slow is because it needs to scan with its regex engine. Same goes for my original perl approach. Your python is faster since you're directly splitting which is more efficient than regex.
 
3:51 PM
@terdon yes, most stupid procedures are fast :)
 
@JacobVlijm Dunno about that. US elections take almost 2 years.
2
 
...Great one! :)
 
4:11 PM
 
4:25 PM
6 days
 
4:38 PM
@Zacharee1 ugly in more then one way
 
wut
 
5:01 PM
New Skype For Linux Alpha Version Released webupd8.org/2016/07/new-skype-for-linux-alpha-released.html
I agree with first four words "Stop using the computer "
 
That's a lazy implementation if I ever saw one
a web wrapper?
come on, MS, you've had two years
 
5:20 PM
so basically ghetto skype? github.com/stanfieldr/ghetto-skype
 
Can anyone get video on the new skype? The video icon is grayed out for me and I can't see anything in the settings.
 
@edwinksl I like that better
 
5:50 PM
@terdon "Video and landline calls are also on their way to Chrome for Linux and Chromebooks: " it says so no :P
Lightning @ tokyo. damn :)
 
@Rinzwind D'oh! Missed that, thanks.
 
watch the video I posted as a penalty :+
 
Holy crap!
 
sure is D:
I bet they will make a anime out of it >:)
 
5:55 PM
bbl :)
 
6:06 PM
Does anybody else find this answer useless? askubuntu.com/a/798250/367990
 
@ByteCommander probably, but it is an attempt to answer the question. The quality is to judge by voting.
 
0
Q: view IPs from apache access.log for date period

WMK83I have seen someone use this command and it works where it pulls back all the IPS in a list/group cat access.* | awk '{ print $1 }' | sort | uniq -c | sort -n however I want to chose the past 2 days, anyone able to point me in the right direction Thanks

 
it's a long and boring generic answer
 
@JacobVlijm Yeah, I don't see a flag reason here either. It's just more a bunch of guesses which most likely won't change a thing.
 
@ByteCommander true of course
 
6:20 PM
0
Q: Set variables into script before or after SCP

FadiI have two scripts out and disk_check.sh. The main script is the out which exports multiple variables but I need two variables set in disk_check.sh which are: VOL and VM_VOLUME. So my out script looks something like this: #!/bin/sh . . . vol="/dev/xvdb" vm_volume="/path/to/dir" # Send disk_...

 
hello all
 
0
Q: edit suggestions: problem with meaningless comments

guntbertI am in a dilemma: There is one user who contributes (very) good edit suggestion but the comments are almost always the same: improved formatting, even if he did a lot more. I do want to get that user to formulate more meaningful comments (to make it easier for reviewers and to provide a usefu...

 
user136984
6:41 PM
@SeverusTux Nope... I don't think that it is... I don't remember asking something like that...
 
Just a heads up Mr. Robot season two episode one, is online. He's using Debian.
 
i have heard very good things about that show
i suppose using debian doesn't harm ;)
 
user136984
6:57 PM
@StefanoPalazzo: They eventually got back to me by the way and sorted out that issue I had! :)
 
Hi
hi @ParanoidPanda, how are you?
 
user136984
@grooveplex: Better than I was yesterday. :)
 
I'm glad
 
7:26 PM
aww I wish I could play around with this app and answer this question... I wanna make an oscilloscope askubuntu.com/questions/798220/…
 
user136984
Someone should star that ^^.
 
yeah you should star mine xD
how to record skype video in a mac .. any clue ?
 
0
Q: Ubuntu MATE LiveCD hangs during VirtualBox boot, weird screen displayed

Keith TweedI downloaded the Ubuntu MATE 16.04 liveCD, and when I booted it with VirtualBox, it hung, and displayed this screen: I modified it with my mediocre GIMP skills to make it easier to read If somebody could tell me what this means, that would be great, as well as how to fix it. Thanks in advance!

 
got the solution
 
8:16 PM
mornin'
 
Should askubuntu.com/q/798305/367990 really be closed as duplicate? The answers of the other questions fit, but the question is different.
 
leave it for now
 
the OP decided it was a duplicate
 
imho dupe, it is fully explained by that accepted answer
 
We close questions as duplicates, not answers.
The old question is how to make apt use HTTPS.
 
8:25 PM
what's the question trying to find out really? whether downloading from repo is safe, and why(/not)?
 
The new question is why apt uses http by default.
 
if OP has decided his/her question is a dupe, i see no reason why we want to dispute it. after all, only the OP truly knows what he/she intended to ask
 
Can I use Ubuntu 16.04 for Assembly programming? A book from 2011 says me I need an Intel x86-based computer running Linux.
 
@PichiWuana yes
 
Thanks!
 
8:28 PM
sure, it is literally different, but I think the difference is just wording. they are looking for the same thing (maybe I spend too much time teaching 17y/os to do comprehension 'what is the author trying to do here?')
 
;D :D D:
 
but, my brain is dead, I should shut up and go do more mindless exam marking...
 
@Zanna what do you teach
 
8:47 PM
many things
but this here exam is physics :)
 
My favourite
 
:) <3
 
user136984
9:06 PM
This guy who is suspended, how come on his chat profile it says he is suspended on the parent site and is unable to chat for 5 days, and yet on the parent site it says 6 days?
 
user136984
Will he be able to chat a day early or something for some reason?
 
9:25 PM
So, I just fresh installed 16.04 on my desktop and now, for whatever reason, my fans are just going crazy
They were fine on my 15.10 install, and now they're running super high and will randomly spike
Any ideas?
 
user136984
@RPiAwesomeness: Well, you could jam them with chocolate cake... That's what I've done with mine... ;P
 
chocolate cake is always a good plan
 
user136984
I really have though... My fan doesn't work due to chocolate cake blockage for about a year now! :D
 
user136984
I have to sort it out at some point actually...
 
@ParanoidPanda >.>
 
9:31 PM
@ParanoidPanda That's exactly why you have 529 questions and 141 answers...
 
user136984
:D
 
user136984
Oh, by the way, how's Trump doing?
 
user136984
Haven't heard much about him in the news recently...
 
Cute message from kern.log before panic:
Uhhuh... Do you have a strange power saving mode enabled?
Dazed and confused, but trying to continue...
(<fffff> etc)
5
 
9:42 PM
lol
 
@Videonauth Warzone movies in place :)
The developer uses theora and vorbis which is nice for a change
 
@andrew.46 where ?
 
2
Q: Warzone 2100: Latest version under Xenial?

andrew.46Xenial Xerus ships with version 3.1.1 of the great game Warzone 2100. A new version has just been released: 2016-07-10 After 3.5 years of development, version 3.2.0 of Warzone has finally been released. Website... How do I get this version under Xenial?

Hmmm... so that is what happens when you post an ask ubuntu link :)
Was not ready for that...
 
lol
 
0
Q: Trick reviews are not helpful

Goran MiskovicWhile reviewing answers I bumped into an answer that looked OK but I noticed that a different user posted already exactly the same answer. Consequently I raised a flag and reported that the answer is just a copy/paste of an existing answer. In response I got: STOP! Look and Listen. This ...

 
9:53 PM
@andrew.46 well i scoured your answer but didnt find a link for a video ?
 
3. Optional: Install the movies:
 
ah ok, i thought you made a small lets play for it :P
 
wget heanet.dl.sourceforge.net/project/warzone2100\
warzone2100/Videos/high-quality-en/sequences.wz
 
showing off your 1337 skillz
xD
 
No, I have put too much work into that answr and question :). Now I leave it to flourish. Hopefully...
 
9:58 PM
O_O
Dat first version of Unity tho
Ouch
 
what versionyou installed ? ubuntu 4.04 ? :p
 
Nah, just watching a vid showing the progression of Ubuntu
 
link :) ?
@edwinksl Time taken = 11928.811463 seconds. (3,31 hours) and that was already the changed version, the other one would have taken double of this.
i guess your solution is for sure nicer :p
 
i didn't really time mine ;)
but definitely not 3 hours ;P
 
i do with all of them
 
10:05 PM
@ByteCommander quite frankly, never noticed strip() takes multple args, in which the order plays no role:
s =  "monkey,,,,,,,!!!\n"
print(s.strip("\n,!"))
 
Mind you my haxxor skills have not allowed me to manually decompress the .wz file :(
 
> monkey
...shocking, but never knew that! Thanks for that.
 
Anonymous
hi everyone!
 
Hi @onebree :)
 
OIC just a zip file
@onebree Hello :)
 
user136984
Goodnight! :)
 
night...
 
so an officer from city animal control came today, showed her the fence, she went over to talk with the neighbors. Hopefully that will have an effect
 
who is going to pay to repair the broken fence
 
No one knows yet. It's a sort of shared fence so she can't tell who it belongs to
For now she will talk to them, and if things continue we may have to file a signed complaint
then those videos can come in handy
 
Anonymous
10:33 PM
hi everyone
 
Anonymous
again
 
Anonymous
how has everyone been since I was here last?
 
Anonymous
I've been really busy with school, work, and learning things for work
 
Anonymous
So I come back, and everyone is silent :P
 
Fine and you ?
extremely busy here too, not much time rally on AU the past week
 
Anonymous
10:36 PM
I've been working on react tutorials and things from egghead.io
 
ohaider
 
Anonymous
hi edity!
 
ohaider
i translate nathan's nitroshare
 
@edwinksl ┌─[00:36:01]─[michael@NEXUS-ONE]
└──> euler $ uname -a
Linux NEXUS-ONE 4.4.0-31-generic #50-Ubuntu SMP Wed Jul 13 00:07:12 UTC 2016 x86_64 x86_64 x86_64 GNU/Linux
 
Anonymous
Cool!
 
Anonymous
10:40 PM
euler is your host name?
 
na directory for python scripts :)
 
Anonymous
Wait, never mind
 
@Videonauth i am about to restart my computer
 
found a new way to count sheep
 
new kernel hype
 
10:41 PM
new kernel?
hope it panics
 
it probably would
 
@Edity this isnt windows :p
 
Anonymous
I "count sheep" by counting back from 99, syncing the count with my breath (slowly), and if I move or twitch I start over. By 85 I am almost trance like and will sleep soon
 
yeah
1 microsoft 2 microsoft 3 microsoft @Videonauth that is how i count sheep
 
@onebree this projecteuler.net/problem=11 is how i count sheep :p
 
Anonymous
10:42 PM
... yeah, I am not solving that
 
plotting the programs in my head, and if i cant sleep even pull up the laptop and write em down
 
project eula
eww mojang eula
 
@onebree yeah thats a tricky one :) but can be done with brute force and an 2d array
 
Anonymous
I mean, hgihest product will also yield the highest sum, correct?
 
 
10:44 PM
pops head in room
3
 
should, yes
o/ kaz
 
Anonymous
That article is over a year old
 
So good news for everyone being excited about the new Skype client.
 
Anonymous
99% likely to have been fixed by now
 
It's literally just Google Chrome.
 
Anonymous
10:46 PM
HAHAHA
 
lol
 
Anonymous
Skype sucks anyway
 
Anonymous
I prefer hangouts.
 
I'm not joking. It's Chromium with bundled NodeJS, and desktop notifications.
Just Skype Online
 
Anonymous
So instead of electron, they are using chromium
 
10:47 PM
so much attack-related stuff
 
Anonymous
Those are old LTS's.. I am on 16
 
Anonymous
There will always be attacks, for as long as we depend on software.
 
And on a chat program? Who uses those ;p
 
Anonymous
I use pidgin
 
Anonymous
Actually... my VM is 15.10 still, but I doubt I will get any strange traffic
 
10:49 PM
thus the ;p face, for sarcasm
 
;P
 
Anonymous
scare-a-sim?
 
>:P\
SIMS CONFIRMED
 
well im off to bed tomorrow a new stressfull day
 
Anonymous
good night video
 
10:54 PM
goodnight @Videonauth
 
Anonymous
It is only 7pm here.. People are leaaving so early
 
11:07 PM
@Videonauth for some reason i apparently solved problem 44
i totally can't recall why i did that
 
11:42 PM
good evening!
 
Greetings!
 
:S
 
I made my coolest bash code so far today, even though I'm not sure if it is thaaat useful
it converse every man file to pdf and save them in a home folder
 
I made my coolest Python today. It responds to nagios requests for data as if it were actually nagios's own reporting agent.
 
what is nagio? an app?
 
11:48 PM
systems monitoring
I had to make a custom approach to it lol
for one server.
 
your script make nagios think you're from nagios?
 
lol
 
btw, thats what my bash code looks like
for manual in /usr/share/man/man[1-8]/*; do zcat $manual | groff -mandoc | ps2pdf - - > ~/BashManuals/$(echo $manual | sed -e 's_\/usr\/share\/man\/man[1-8]\/__' -e 's_\.gz$_\.pdf_'); done
 
@IanC the script I run is a daemon that listens on the port that nagios agent (what nagios server reaches out to for data and uptime status on the server) normally does, and provides responses to anything that Nagios would request per its configuration
 
wanted to practice groff, sed, regex and even had to check for loops (which I didn't get to in the book I'm reading yet, but sound quite easy)
 
11:50 PM
had to because nagios agent wouldn't compile heh
 
ooooh, I get it now!
you readed the nagio agent source code to find what the requests and answers looked like?
 
nope
tracked network packets
to the boxes which had the agent
sniffed the traffic
determined the requests
wrote methods for it in python for the one box
 
cool :D
wish I had the knowledge to do those walk-arounds when something didn't work as it should here haha
I'm starting to get a better feel of how the system works though
you used wshark to get those network packets and evaluate them?
 
yep. dissected the packets and traffic
 

« first day (2114 days earlier)      last day (2844 days later) »