git: a6617f42bb - main - ports.cgi: indent

Wolfram Schneider <[email protected]>
Newsgroups gmane.os.freebsd.devel.cvs.doc
Message-ID <[email protected]>
The branch main has been updated by wosch:

URL: https://cgit.FreeBSD.org/doc/commit/?id=a6617f42bbc222199c337bf707343a287908f39f

commit a6617f42bbc222199c337bf707343a287908f39f
Author:     Wolfram Schneider <[email protected]>
AuthorDate: 2026-03-07 10:35:57 +0000
Commit:     Wolfram Schneider <[email protected]>
CommitDate: 2026-03-07 10:35:57 +0000

    ports.cgi: indent
---
 website/content/en/cgi/ports.cgi | 38 ++++++++++++++++++++++----------------
 1 file changed, 22 insertions(+), 16 deletions(-)

diff --git a/website/content/en/cgi/ports.cgi b/website/content/en/cgi/ports.cgi
index 8830c2389e..c036f4665a 100755
--- a/website/content/en/cgi/ports.cgi
+++ b/website/content/en/cgi/ports.cgi
@@ -114,7 +114,7 @@ my $max;
 my $debug = 1;
 
 # feature flags
-my $enable_packages_link = 1;
+my $enable_packages_link              = 1;
 my $enable_check_freebsd_mailing_list = 1;
 
 my %lists;
@@ -330,7 +330,8 @@ sub out {
     $path     =~ s/^$localPrefix/$remotePrefixFtp/o;
     $descfile =~ s/^$localPrefix/$remotePrefixFtp/o;
     $version = &encode_url($version);
-    $email = &check_freebsd_mailing_list($email) if $enable_check_freebsd_mailing_list;
+    $email   = &check_freebsd_mailing_list($email)
+      if $enable_check_freebsd_mailing_list;
 
     #$version =~ s/[\+,]/X/g;
 
@@ -419,12 +420,12 @@ sub package_links {
         chomp;
         next if !(m,^(.*?)-(.*?)\.yaml:(.*),);
 
-        my $arch     = $1;
+        my $arch      = $1;
         my $rel_major = $1;
         my $rel_minor = "$1/$2";
-        my $snapshot = $2;
-        my $path     = "$1/$2";
-        my $perl     = decode_json($3);
+        my $snapshot  = $2;
+        my $path      = "$1/$2";
+        my $perl      = decode_json($3);
 
         $arch =~ s,.*%3A,,;
         if ( $rel_major =~ /^FreeBSD%3A(\d+)%3A/ ) {
@@ -432,7 +433,8 @@ sub package_links {
         }
         if ( $rel_minor =~ /^FreeBSD%3A(\d+)%3A.*release_(\d+)$/ ) {
             $rel_minor = ":$1:$2";
-        } else {
+        }
+        else {
             $rel_minor = "";
         }
 
@@ -448,7 +450,8 @@ sub package_links {
               . qq[</a><br/>\n];
 
             my $maintainer = $perl->{"maintainer"};
-            $maintainer = &check_freebsd_mailing_list($maintainer) if $enable_check_freebsd_mailing_list;
+            $maintainer = &check_freebsd_mailing_list($maintainer)
+              if $enable_check_freebsd_mailing_list;
             print qq[maintainer: $maintainer<br/>\n];
 
             print qq[<h3>Description</h3>\n];
@@ -490,12 +493,12 @@ qq{ <th onclick="sort_table(2)" title="click to sort asc/desc by build time">Bui
 
         if ($filter) {
             next
-              if index( $release, $filter ) < 0
-              && index( $pkg_opt, $filter ) < 0
+              if index( $release,   $filter ) < 0
+              && index( $pkg_opt,   $filter ) < 0
               && index( $rel_minor, $filter ) < 0
-              && index( $version, $filter ) < 0
-              && index( $time,    $filter ) < 0
-              && index( $flavor,  $filter ) < 0;
+              && index( $version,   $filter ) < 0
+              && index( $time,      $filter ) < 0
+              && index( $flavor,    $filter ) < 0;
         }
 
         next if $counter >= $max;
@@ -793,10 +796,10 @@ EOF
 sub check_freebsd_mailing_list {
     my $email = shift;
 
-    my ($user, $hostname) = split('@', $email);
+    my ( $user, $hostname ) = split( '@', $email );
 
     # email is a ports section, not a real user
-    if ($lists{$user}) {
+    if ( $lists{$user} ) {
         $user = 'freebsd-' . $user;
     }
 
@@ -849,7 +852,10 @@ if ( !$query && $query_string =~ /^([^=&]+)$/ ) {
 @sec = &readcoll;
 
 # mailing list aliases
-%lists = map { $_ => 1 } qw/apache chromium desktop elastic emulation enlightenment erlang fortran gecko gnome go haskell java multimedia office perl pkg ports python ruby tcltk tex uboot x11 xfce zope/;
+%lists = map { $_ => 1 }
+  qw/apache chromium desktop elastic emulation enlightenment erlang fortran
+  gecko gnome go haskell java multimedia office perl pkg ports python ruby
+  tcltk tex uboot x11 xfce zope/;
 
 $query = &check_query( $query, $sourceid );
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.