diff options
Diffstat (limited to 'zarb-ml/mageia-dev/2011-December/010342.html')
-rw-r--r-- | zarb-ml/mageia-dev/2011-December/010342.html | 121 |
1 files changed, 121 insertions, 0 deletions
diff --git a/zarb-ml/mageia-dev/2011-December/010342.html b/zarb-ml/mageia-dev/2011-December/010342.html new file mode 100644 index 000000000..b71ca7aa1 --- /dev/null +++ b/zarb-ml/mageia-dev/2011-December/010342.html @@ -0,0 +1,121 @@ +<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN"> +<HTML> + <HEAD> + <TITLE> [Mageia-dev] [soft-commits] [2359] coding style update (perl_checker) + </TITLE> + <LINK REL="Index" HREF="index.html" > + <LINK REL="made" HREF="mailto:mageia-dev%40mageia.org?Subject=Re%3A%20%5BMageia-dev%5D%20%5Bsoft-commits%5D%20%5B2359%5D%20coding%20style%20update%0A%09%28perl_checker%29&In-Reply-To=%3CCAONrEtYo2Grpag0otVOaupD3irD_SJPF2FH1L5sKhLM9FYCi%3Dg%40mail.gmail.com%3E"> + <META NAME="robots" CONTENT="index,nofollow"> + <META http-equiv="Content-Type" content="text/html; charset=us-ascii"> + <LINK REL="Previous" HREF="010340.html"> + <LINK REL="Next" HREF="010344.html"> + </HEAD> + <BODY BGCOLOR="#ffffff"> + <H1>[Mageia-dev] [soft-commits] [2359] coding style update (perl_checker)</H1> + <B>Thierry Vignaud</B> + <A HREF="mailto:mageia-dev%40mageia.org?Subject=Re%3A%20%5BMageia-dev%5D%20%5Bsoft-commits%5D%20%5B2359%5D%20coding%20style%20update%0A%09%28perl_checker%29&In-Reply-To=%3CCAONrEtYo2Grpag0otVOaupD3irD_SJPF2FH1L5sKhLM9FYCi%3Dg%40mail.gmail.com%3E" + TITLE="[Mageia-dev] [soft-commits] [2359] coding style update (perl_checker)">thierry.vignaud at gmail.com + </A><BR> + <I>Sat Dec 10 20:37:35 CET 2011</I> + <P><UL> + <LI>Previous message: <A HREF="010340.html">[Mageia-dev] [soft-commits] [2359] coding style update (perl_checker) +</A></li> + <LI>Next message: <A HREF="010344.html">[Mageia-dev] [soft-commits] [2359] coding style update (perl_checker) +</A></li> + <LI> <B>Messages sorted by:</B> + <a href="date.html#10342">[ date ]</a> + <a href="thread.html#10342">[ thread ]</a> + <a href="subject.html#10342">[ subject ]</a> + <a href="author.html#10342">[ author ]</a> + </LI> + </UL> + <HR> +<!--beginarticle--> +<PRE>On 10 December 2011 20:25, Romain d'Alverny <<A HREF="https://www.mageia.org/mailman/listinfo/mageia-dev">rdalverny at gmail.com</A>> wrote: +>><i> just do sg like this: +</I>>><i> [...] +</I>>><i>    if ((@info{qw(name version release variant arch medium build +</I>>><i> ext)}) = $name =~ +</I>>><i>        m/^(Mageia)-(\d+)-((?:alpha|beta|RC)\d*)?(-(?:.*))?-(i586|x86_64|dual)?(?:-(CD|DVD|BD))?(?:-(build_\w+))?\.(.*)$/) +</I>>><i> { +</I>>><i>        $info{full} = $name; +</I>>><i>    } +</I>>><i> [...] +</I>><i> +</I>><i> Looks much more compact, thanks. Added a "else { %info = (); }" to +</I>><i> satisfy the expected behaviour (empty array returned if no match). +</I> +This is wrong. +Once declared (aka "my %info"), %info is initialized and is equal to "()". + +>>><i>  open(my $file, "temp_media_on_iso.log") if -r "temp_media_on_iso.log"; +</I>>>><i> +</I>>>><i>  while ($media = <$file>) { +</I>>><i> +</I>>><i> just reuse cat_() from MDK::Common (simpler, easier to read) +</I>><i> +</I>><i> Thanks! +</I>><i> +</I>><i> By the way, is there a "best" Web-based doc for MDK Perl libraries? +</I>><i> (could find one, but not at once, and I didn't count many). Or shall +</I>><i> we think about it? +</I> +perldoc MDK::Common + +I've locally a branch adding doc for drakx but it's not finished. +</PRE> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +<!--endarticle--> + <HR> + <P><UL> + <!--threads--> + <LI>Previous message: <A HREF="010340.html">[Mageia-dev] [soft-commits] [2359] coding style update (perl_checker) +</A></li> + <LI>Next message: <A HREF="010344.html">[Mageia-dev] [soft-commits] [2359] coding style update (perl_checker) +</A></li> + <LI> <B>Messages sorted by:</B> + <a href="date.html#10342">[ date ]</a> + <a href="thread.html#10342">[ thread ]</a> + <a href="subject.html#10342">[ subject ]</a> + <a href="author.html#10342">[ author ]</a> + </LI> + </UL> + +<hr> +<a href="https://www.mageia.org/mailman/listinfo/mageia-dev">More information about the Mageia-dev +mailing list</a><br> +</body></html> |