Re: [arch-general] grep

2019-10-15 Thread Ralph Corderoy
Hi Silvio,

$ grep ^ */*
de/1.md:date: 2019-10-10
de/2.md:date: 2019-10-12
de/3.md:date: 2019-10-14
de/4.md:date: 2019-10-16
en/1.md:date: 2019-10-10
en/2.md:date: 2019-10-12
en/3.md:date: 2019-10-14
en/4.md:date: 2019-10-16
fr/4.md:date: 2019-10-16
ru/3.md:date: 2019-10-14
ru/4.md:date: 2019-10-16
$
$ grep -hm1 '^date:' */* | 
> sort -Vu |
> while read -r d; do 
> for l in ??; do
> fgrep -qrx "$d" $l || echo "$d $l"
> done
> done |
> sed 's/^date: //' |
> sort
2019-10-10 fr
2019-10-10 ru
2019-10-12 fr
2019-10-12 ru
2019-10-14 fr
$

-- 
Cheers, Ralph.


Re: [arch-general] grep

2019-10-15 Thread siefke_lis...@web.de
Hello, 

On Mon, 14 Oct 2019 22:23:49 +0200 (CEST)
"Jeanette C. via arch-general"  wrote:

> Hey hey Silvio,
> hm this looks more like a challenge for a whole script. I can script, but I'm 
> not always the most efficient.

Yes you right I had think it would be one line :). No worried I search not 
efficient, it will be only a help in the daily hobby project. Every time 
manuell run grep make sick on a computer which are build to make our life
easier :) 

> If your .md files always look the same, i.e. there is always the exact line 
> "date: -mm-dd" and you can be sure that one script folder will have all 
> articles, because they are originally written in that language, I'd have an 
> idea. 

Yes this files are markdown text files with a header and the content text. 

---
title: "Title"
date: 2019-10-15
tags: "Gesellschaft"
shorttext: ""
draft: false
lang: de
cover: "society"
---

So date is in every file and ever in same format because the date formatting
make hugo when build the pages.

> Say your articles are all created in German:
> grep -e "date: 2019-10-1" content/de/blog/*.md >orig.list
> LINES=`wc -l orig.list | awk '{ print $2 }'` # get number of entries
> # do the same for the ohter folders:
> grep -e "date: 2019-10-1" content/en/blog/*.md >en.list
> grep -e "date: 2019-10-1" content/fr/blog/*.md >fr.list
> # complete for other folders

This work it give files and content like: 

$ cat de.list 
content/de/blog/die-grΓΌnen-heuchler.md:date: 2019-10-16
content/de/blog/die-killer.md:date: 2019-10-17



> # now check
> CURLINE=1
> while [[ $CURLINE -le $LINES ]]; do
>CURDATE=`sed -n ${CURLINE}p orig.list # get an article date
>for FILE in en.list fr.list ru.list and_so_on; do
>  COUNT=`grep -c -e "${CURDATE}" ${FILE}
>if [[ $COUNT -eq 0 ]]; then # not found in translation
>  echo ${CURDATE} missing in ${FILE}" >missing.files;
>  fi;
>done
>let CURLINE=CURLINE+1; # go to next original date
> done
> rm *.list # remove your temporary files

But this will not work. There is no output at end with a bit 
playing it run endless or there come Syntax Errors. But an Idea 
is born. 



-- 
Nice Day & Thank you
Silvio


pgpO5ho_BIPUx.pgp
Description: PGP signature


Re: [arch-general] grep

2019-10-15 Thread siefke_lis...@web.de
Hello, 


> for file in content/en/blog/*.md; do
>   basefile=$(basename "$file" .md)
>   if [[ ! -e content/de/blog/"$basefile" ]]; then
> echo "German is missing $basefile";
>   fi;
> done;
> 
> Perhaps?

Basename will not work cause the file name have different names in the
languages blog folder. Only date is what can be used at all because this
stand in header of every markdown field. 
 
> Maybe instead you're saying that the dates present in one language should
> also be present in another language? That would be a pretty different
> solution with which I'm happy to help if you indicate such a desire.

Yes the dates are ever present. 

-- 
Thank you & Nice day

Silvio


pgpHabTJphAVw.pgp
Description: PGP signature


Re: [arch-general] Package guidelines πŸ“¦

2019-10-15 Thread Alberto Salvia Novella via arch-general

You are right, I shall not follow drama up on comments like these.

If a message looks malicious I shall simply skip reading it, and 
silently filter re-incident people.




Re: [arch-general] Package guidelines πŸ“¦

2019-10-15 Thread Emil Lundberg via arch-general
On 2019-10-15 14:23, Fabian Piribauer via arch-general wrote:
> It's debetable if calling a idea stupid is rude, but just cutting off
> all communication because you feel offended is not the way to go. If he
> really wanted to improve things, he should have noted the tone as side
> note after adressing the mentoined issues with his proposal.

Agreed.

/Emil





Re: [arch-general] Kernel 5.3.5 and Kernel 5.3.6 perl warnings

2019-10-15 Thread Jude DaShiell
This doesn't happen with earlier kernel versions.  A contact I have uses
a Raspburry pi and he doesn't have this problem yet.  If I comment the
source /etc/locale.conf line out in my .bash_profile file, the perl
warnings come back on next reboot or until after I source .bash_profile.

On Tue, 15 Oct 2019, Ram Kumar via arch-general wrote:

> Date: Mon, 14 Oct 2019 22:53:44
> From: Ram Kumar via arch-general 
> To: General Discussion about Arch Linux 
> Cc: Ram Kumar 
> Subject: Re: [arch-general] Kernel 5.3.5 and Kernel 5.3.6 perl warnings
>
> Thank you Jude..
>
> On Tue, 15 Oct 2019 at 07:16, Jude DaShiell  wrote:
>
> > If you start getting warnings that perl failed to set locale that didn't
> > happen on earlier versions of the kernel I know how to fix that.
> > First you have to have everything correct in /etc/locale.conf.  If that's
> > the case, add to your ~/.bash_profile file
> > source /etc/locale.conf then save the edit and do source ~/.bash_profile
> > then run your perl application like maybe cpanplus or irssi and
> > if everything works on your system like it does on my system you won't get
> > those warnings again.
> >
> >
> >
> > --
> >
>

-- 


Re: [arch-general] Package guidelines πŸ“¦

2019-10-15 Thread Fabian Piribauer via arch-general
> On 2019-10-14 17:22, Doug Newgard via arch-general wrote:
> > On Mon, 14 Oct 2019 17:17:09 +0200
> > Alberto Salvia Novella via arch-general  wrote:
> >
> >> Robin Broda:
> >>> This is universally stupid.  
> >> abrasiveness = blockage
> >>
> > LOL, blocking a TU who's making valid points.
> >
> > This thread was going nowhere in the first place, so I guess it doesn't 
> > matter.

Indeed, this thread will go no where. Note that this guy has already
been banned from the forums because he has pulled similiar stunts there
aswell [1].

On Tue, Oct 15, 2019 at 01:25:49PM +0200, Emil Lundberg via arch-general wrote:
> Maybe it's just me, but I don't think it seems appropriate for a TU to
> respond like that to a member of the community. It's certainly doesn't
> make for a welcoming atmosphere. Even though Arch is not for everyone,
> there's no need to actively drive people away by being rude. I also
> don't think authority is a good excuse for being rude - quite the
> opposite, in fact.

It's debetable if calling a idea stupid is rude, but just cutting off
all communication because you feel offended is not the way to go. If he
really wanted to improve things, he should have noted the tone as side
note after adressing the mentoined issues with his proposal.

[1]: https://bbs.archlinux.org/profile.php?id=113614


signature.asc
Description: PGP signature


Re: [arch-general] Package guidelines πŸ“¦

2019-10-15 Thread Emil Lundberg via arch-general
Maybe it's just me, but I don't think it seems appropriate for a TU to
respond like that to a member of the community. It's certainly doesn't
make for a welcoming atmosphere. Even though Arch is not for everyone,
there's no need to actively drive people away by being rude. I also
don't think authority is a good excuse for being rude - quite the
opposite, in fact.

/Emil


On 2019-10-14 17:22, Doug Newgard via arch-general wrote:
> On Mon, 14 Oct 2019 17:17:09 +0200
> Alberto Salvia Novella via arch-general  wrote:
>
>> Robin Broda:
>>> This is universally stupid.  
>> abrasiveness = blockage
>>
> LOL, blocking a TU who's making valid points.
>
> This thread was going nowhere in the first place, so I guess it doesn't 
> matter.


Re: [arch-general] grep

2019-10-15 Thread Ralph Corderoy
Hi Silvio,

> How can I do the same in the other folders and all those that exist
> with the same date are hidden and when no file is present give out the
> file which is missing in other folders sort by date. The name of file
> is sure other, but the date is ever the same.

The requirement is unclear.  Given this input,

$ grep ^ */*
de/1.md:date: 2019-10-10
de/2.md:date: 2019-10-12
de/3.md:date: 2019-10-14
de/4.md:date: 2019-10-16
en/1.md:date: 2019-10-10
en/2.md:date: 2019-10-12
en/3.md:date: 2019-10-14
en/4.md:date: 2019-10-16
fr/4.md:date: 2019-10-16
ru/3.md:date: 2019-10-14
ru/4.md:date: 2019-10-16
$

what output do you require?

-- 
Cheers, Ralph.


[arch-general] Package guidelines πŸ“¦

2019-10-15 Thread Maksim Fomin via arch-general
‐‐‐ Original Message ‐‐‐
On Monday, October 14, 2019 8:59 PM, Alberto Salvia Novella via arch-general 
 wrote:

> Video-reply https://youtu.be/a_CNx63kLxk

Why so serious?

Seriously, why is this thread not nuked?