From 7783fcad586608d15efe50957c80d1d5b7bf7432 Mon Sep 17 00:00:00 2001 From: "Yury V. Zaytsev" Date: Sun, 20 Oct 2024 18:09:13 +0200 Subject: [PATCH] maint: remove obsolete CI/maint and re-implement source index Signed-off-by: Yury V. Zaytsev --- .github/workflows/update-sources.yml | 48 +++++ .travis.yml | 31 --- {maint/docs => doc}/RELEASE_PROCEDURE | 0 maint/docs/COMMIT_PROCEDURE | 4 - maint/docs/README | 7 - maint/docs/systems.txt | 9 - maint/{utils => }/doctest | 0 .../find-dup-includes/exclude-list.cfg | 0 .../find-dup-includes/find-in-one-file.pl | 0 maint/{utils => }/find-dup-includes/runme.sh | 0 maint/htagsfix | 180 ++++++++++++++++++ maint/{utils => }/sync-transifex/.gitignore | 0 maint/{utils => }/sync-transifex/README.md | 0 .../sync-transifex/config.d/mc.hint/po4a.cfg | 0 .../sync-transifex/config.d/mc.hint/tx.config | 0 .../sync-transifex/config.d/mc.pot/tx.config | 0 .../sync-transifex/hints-from-transifex.py | 0 .../sync-transifex/hints-to-transifex.py | 0 .../sync-transifex/po-from-transifex.py | 0 .../sync-transifex/po-to-transifex.py | 0 .../sync-transifex/translation_utils.py | 0 maint/{utils => }/unrefglobals.pl | 0 maint/{utils => }/update-years.sh | 0 maint/utils/check-indent.sh | 47 ----- maint/utils/deploy-key.enc | Bin 1680 -> 0 bytes maint/utils/deploy-key.pub | 1 - maint/utils/travis-build.sh | 105 ---------- maint/utils/travis-deploy.sh | 71 ------- 28 files changed, 228 insertions(+), 275 deletions(-) create mode 100644 .github/workflows/update-sources.yml delete mode 100644 .travis.yml rename {maint/docs => doc}/RELEASE_PROCEDURE (100%) delete mode 100644 maint/docs/COMMIT_PROCEDURE delete mode 100644 maint/docs/README delete mode 100644 maint/docs/systems.txt rename maint/{utils => }/doctest (100%) rename maint/{utils => }/find-dup-includes/exclude-list.cfg (100%) rename maint/{utils => }/find-dup-includes/find-in-one-file.pl (100%) rename maint/{utils => }/find-dup-includes/runme.sh (100%) create mode 100755 maint/htagsfix rename maint/{utils => }/sync-transifex/.gitignore (100%) rename maint/{utils => }/sync-transifex/README.md (100%) rename maint/{utils => }/sync-transifex/config.d/mc.hint/po4a.cfg (100%) rename maint/{utils => }/sync-transifex/config.d/mc.hint/tx.config (100%) rename maint/{utils => }/sync-transifex/config.d/mc.pot/tx.config (100%) rename maint/{utils => }/sync-transifex/hints-from-transifex.py (100%) rename maint/{utils => }/sync-transifex/hints-to-transifex.py (100%) rename maint/{utils => }/sync-transifex/po-from-transifex.py (100%) rename maint/{utils => }/sync-transifex/po-to-transifex.py (100%) rename maint/{utils => }/sync-transifex/translation_utils.py (100%) rename maint/{utils => }/unrefglobals.pl (100%) rename maint/{utils => }/update-years.sh (100%) delete mode 100755 maint/utils/check-indent.sh delete mode 100644 maint/utils/deploy-key.enc delete mode 100644 maint/utils/deploy-key.pub delete mode 100755 maint/utils/travis-build.sh delete mode 100755 maint/utils/travis-deploy.sh diff --git a/.github/workflows/update-sources.yml b/.github/workflows/update-sources.yml new file mode 100644 index 0000000000..a5ec277feb --- /dev/null +++ b/.github/workflows/update-sources.yml @@ -0,0 +1,48 @@ +name: update-sources + +on: + push: + branches: + - master + +jobs: + update-sources: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + + - name: Install GNU Global + run: sudo apt-get install -y global exuberant-ctags python3-pygments + + - name: Checkout source repo + uses: actions/checkout@v4 + with: + repository: MidnightCommander/source + path: HTML + ref: gh-pages + ssh-key: ${{ secrets.SOURCE_DEPLOY_KEY }} + + - name: Create sources index + run: | + pushd HTML + git rm -rf * + popd + + gtags + htags --suggest -t "Welcome to the Midnight Commander source tour!" + ./maint/htagsfix + + - name: Deploy to GitHub + run: | + cd HTML + + touch .nojekyll + echo "source.midnight-commander.org" > CNAME + + git config user.name "GitHub Actions" + git config user.email "github@midnight-commander.org" + + git add . + git commit -m "Deploy to GitHub Pages" + + git push --force-with-lease diff --git a/.travis.yml b/.travis.yml deleted file mode 100644 index 701d3f471b..0000000000 --- a/.travis.yml +++ /dev/null @@ -1,31 +0,0 @@ -language: c -sudo: true - -env: - - CFLAGS=-Wno-error=shadow - -install: - - sudo apt-get update -qq - - sudo apt-get install -y autoconf gettext autopoint libtool check indent - - sudo apt-get install -y e2fslibs-dev libaspell-dev libglib2.0-dev libgpm-dev libncurses5-dev libslang2-dev libssh2-1-dev libx11-dev unzip - - sudo apt-get install -y wget exuberant-ctags python-pygments ruby - -before_script: - - git fetch --tags - -script: - - ./maint/utils/check-indent.sh - - ./autogen.sh - - ./maint/utils/travis-build.sh - -after_success: - - openssl aes-256-cbc -K $encrypted_036881b9e9dd_key -iv $encrypted_036881b9e9dd_iv -in ./maint/utils/deploy-key.enc -out $HOME/.ssh/deploy-key -d - - chmod 600 $HOME/.ssh/deploy-key - - echo "Host github.com" >> $HOME/.ssh/config - - echo " IdentityFile ~/.ssh/deploy-key" >> $HOME/.ssh/config - -deploy: - provider: script - script: ./maint/utils/travis-deploy.sh - on: - branch: master diff --git a/maint/docs/RELEASE_PROCEDURE b/doc/RELEASE_PROCEDURE similarity index 100% rename from maint/docs/RELEASE_PROCEDURE rename to doc/RELEASE_PROCEDURE diff --git a/maint/docs/COMMIT_PROCEDURE b/maint/docs/COMMIT_PROCEDURE deleted file mode 100644 index aff68d76db..0000000000 --- a/maint/docs/COMMIT_PROCEDURE +++ /dev/null @@ -1,4 +0,0 @@ -Please run the following command: -make indent -in the build root directory before each new commit. - diff --git a/maint/docs/README b/maint/docs/README deleted file mode 100644 index 2e6e7fe414..0000000000 --- a/maint/docs/README +++ /dev/null @@ -1,7 +0,0 @@ -This directory contains files used to maintain the project. -It should not be included into any releases or even snapshots. - -Please run periodically the following command: -make cppcheck -in the build root directory. Fix as possible all code analysis -issues which found by the command. diff --git a/maint/docs/systems.txt b/maint/docs/systems.txt deleted file mode 100644 index ca5d7a40cb..0000000000 --- a/maint/docs/systems.txt +++ /dev/null @@ -1,9 +0,0 @@ -This is a list of system configurations that we test the Midnight -Commander on. Feel free to add your own entries. To get your system -identification, run config.guess from the config subdirectory. - -i386-unknown-freebsd4.11 Roland Illig -i386-unknown-netbsdelf1.6.2 Roland Illig -i686-pc-linux-gnu (SuSE 7.2) Roland Illig -powerpc-ibm-aix4.3.3.0 Roland Illig -sparc-sun-solaris2.8 Roland Illig diff --git a/maint/utils/doctest b/maint/doctest similarity index 100% rename from maint/utils/doctest rename to maint/doctest diff --git a/maint/utils/find-dup-includes/exclude-list.cfg b/maint/find-dup-includes/exclude-list.cfg similarity index 100% rename from maint/utils/find-dup-includes/exclude-list.cfg rename to maint/find-dup-includes/exclude-list.cfg diff --git a/maint/utils/find-dup-includes/find-in-one-file.pl b/maint/find-dup-includes/find-in-one-file.pl similarity index 100% rename from maint/utils/find-dup-includes/find-in-one-file.pl rename to maint/find-dup-includes/find-in-one-file.pl diff --git a/maint/utils/find-dup-includes/runme.sh b/maint/find-dup-includes/runme.sh similarity index 100% rename from maint/utils/find-dup-includes/runme.sh rename to maint/find-dup-includes/runme.sh diff --git a/maint/htagsfix b/maint/htagsfix new file mode 100755 index 0000000000..c0db95e204 --- /dev/null +++ b/maint/htagsfix @@ -0,0 +1,180 @@ +#!/usr/bin/env ruby + +# +# Fixes htags' output so that files have fixed names. E.g., S/542.html -> D/whatever.c.h. +# +# It addresses the following problem: +# +# "Can htags create permanent addresses?" +# http://lists.gnu.org/archive/html/help-global/2015-11/msg00002.html +# + +require 'fileutils' +require 'pp' + +Encoding.default_external = "BINARY" + +$base = '.' # Where the HTML is stored. +$verbose = false +$debug = false +$create_subdirs = false # Experimental feature. Doesn't really work. + +# Bonus: highlight the target line. +$css = " +a:target { + position: absolute; + left: 0; + height: 1.35em; + width: 100%; + background: yellow; + opacity: .5; + z-index: -1000; +} +" + +# +# Computes pretty names for files: +# +# '.../S/456.html' => 'S/modules/tty.c.html' +# +def prettyname(full_path, prefix, kind, nid, ext) + gist = nid + start = IO.read(full_path, 1024) + if start =~ /(.*?)<\/title>/ then + gist = $1 + gist.gsub!(%r{/+$}, '') # remove trailing '/'s. + if not $create_subdirs then + gist.gsub!('/', '--') + end + gist.gsub!(%r{[^a-zA-Z0-9_.,/-]}, '-') # clean special characters. + end + return kind + '/' + gist + ext +end + +class Counter + class << self + def init(total) + @total = total + end + def reset() + @count = 0 + end + def report() + print "[#{@count}/#{@total}]\r" + @count += 1 + end + def finish() + puts + end + end +end + +# +# Returns a table explaining how to rename the files. E.g.: +# +# { +# 'S/456.html' => 'S/modules/tty.c.html' +# ... +# } +# +def build_cnv_tbl() + Counter.reset() + cnv = {} + Dir[$base + '/{[A-Z],files}/*.html'].each do |full_path| + #p full_path + if full_path =~ /(.*)\/((\w+)\/(\d+)(\.\w+))$/ then + prefix = $1 # "/home/joe/.../HTML" + path = $2 # "S/323.html" + kind = $3 # "S" + nid = $4 # "323" + ext = $5 # ".html" + pretty = prettyname(full_path, prefix, kind, nid, ext) + cnv[path] = pretty + end + Counter.report() + end + Counter.finish() + return cnv +end + +# +# Make all the substiutions inside the files: +# +# <a href='../S/456.html'> --> <a href='../S/modules/tty.c.html'> +# ... +# +def mksub(cnv) + Counter.reset() + Dir[$base + '/**/*.html'].each do |path| + kind = path[$base.length .. -1][/\w+/] + text = IO.read(path) + fixed = text.gsub(/(<a href='(?:..\/)?)([^'#]+)/) do |a| + prefix = $1 + target = $2 + if cnv[target] then + target = cnv[target] + elsif cnv[kind + '/' + target] then + # This is a relative link of the form: href='456.html' + if cnv[kind + '/' + target].match /\/(.*)/ # converts "s/whatever.html" to "whatever.html" + target = $1 + end + end + prefix + target + end + + # Fix a problem in Opera, where empty lines are squashed. + fixed.gsub!(%r{(<a id='L\d+' name='L\d+'></a>)\n}, "\\1 \n") + + if text != fixed then + IO.write(path, fixed) + puts(path + " modified") if $debug + end + Counter.report() + end + Counter.finish() +end + +# +# Rename the files. +# +def rename(cnv) + Counter.reset() + cnv.each do |a, b| + src = $base + '/' + a + trg = $base + '/' + b + if $create_subdirs then + FileUtils.mkdir_p(File.dirname(trg)) + end + File.rename(src, trg) + Counter.report() + end + Counter.finish() +end + +def better_css(css_path) + text = IO.read(css_path) + IO.write(css_path, text + $css) +end + +def main() + if not File.exists?($base + '/help.html') then + $base += '/HTML' + if not File.exists?($base + '/help.html') then + puts "Error: This doesn't look like htags' output directory." + exit(1) + end + end + Counter.init( Dir[$base + '/**/*.html'].length ) + puts "Figuring out pretty names..." + cnv = build_cnv_tbl() + pp cnv if $verbose + puts "Updating links in files..." + mksub(cnv) + puts "Renaming files..." + rename(cnv) + puts "Enhancing the css..." + better_css($base + '/style.css') + puts "Done." +end + +main() diff --git a/maint/utils/sync-transifex/.gitignore b/maint/sync-transifex/.gitignore similarity index 100% rename from maint/utils/sync-transifex/.gitignore rename to maint/sync-transifex/.gitignore diff --git a/maint/utils/sync-transifex/README.md b/maint/sync-transifex/README.md similarity index 100% rename from maint/utils/sync-transifex/README.md rename to maint/sync-transifex/README.md diff --git a/maint/utils/sync-transifex/config.d/mc.hint/po4a.cfg b/maint/sync-transifex/config.d/mc.hint/po4a.cfg similarity index 100% rename from maint/utils/sync-transifex/config.d/mc.hint/po4a.cfg rename to maint/sync-transifex/config.d/mc.hint/po4a.cfg diff --git a/maint/utils/sync-transifex/config.d/mc.hint/tx.config b/maint/sync-transifex/config.d/mc.hint/tx.config similarity index 100% rename from maint/utils/sync-transifex/config.d/mc.hint/tx.config rename to maint/sync-transifex/config.d/mc.hint/tx.config diff --git a/maint/utils/sync-transifex/config.d/mc.pot/tx.config b/maint/sync-transifex/config.d/mc.pot/tx.config similarity index 100% rename from maint/utils/sync-transifex/config.d/mc.pot/tx.config rename to maint/sync-transifex/config.d/mc.pot/tx.config diff --git a/maint/utils/sync-transifex/hints-from-transifex.py b/maint/sync-transifex/hints-from-transifex.py similarity index 100% rename from maint/utils/sync-transifex/hints-from-transifex.py rename to maint/sync-transifex/hints-from-transifex.py diff --git a/maint/utils/sync-transifex/hints-to-transifex.py b/maint/sync-transifex/hints-to-transifex.py similarity index 100% rename from maint/utils/sync-transifex/hints-to-transifex.py rename to maint/sync-transifex/hints-to-transifex.py diff --git a/maint/utils/sync-transifex/po-from-transifex.py b/maint/sync-transifex/po-from-transifex.py similarity index 100% rename from maint/utils/sync-transifex/po-from-transifex.py rename to maint/sync-transifex/po-from-transifex.py diff --git a/maint/utils/sync-transifex/po-to-transifex.py b/maint/sync-transifex/po-to-transifex.py similarity index 100% rename from maint/utils/sync-transifex/po-to-transifex.py rename to maint/sync-transifex/po-to-transifex.py diff --git a/maint/utils/sync-transifex/translation_utils.py b/maint/sync-transifex/translation_utils.py similarity index 100% rename from maint/utils/sync-transifex/translation_utils.py rename to maint/sync-transifex/translation_utils.py diff --git a/maint/utils/unrefglobals.pl b/maint/unrefglobals.pl similarity index 100% rename from maint/utils/unrefglobals.pl rename to maint/unrefglobals.pl diff --git a/maint/utils/update-years.sh b/maint/update-years.sh similarity index 100% rename from maint/utils/update-years.sh rename to maint/update-years.sh diff --git a/maint/utils/check-indent.sh b/maint/utils/check-indent.sh deleted file mode 100755 index daa612ad32..0000000000 --- a/maint/utils/check-indent.sh +++ /dev/null @@ -1,47 +0,0 @@ -#!/bin/bash -# -# Midnight Commander - check source code indentation -# -# Copyright (C) 2015 -# The Free Software Foundation, Inc. -# -# Written by: -# Slava Zanko <slavazanko@gmail.com>, 2015 -# -# This file is part of the Midnight Commander. -# -# The Midnight Commander is free software: you can redistribute it -# and/or modify it under the terms of the GNU General Public License as -# published by the Free Software Foundation, either version 3 of the License, -# or (at your option) any later version. -# -# The Midnight Commander is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with this program. If not, see <http://www.gnu.org/licenses/>. - -set -e -set -x - -findUnindentedFiles() { - local directory=$1 - find "${directory}" -name '*.[ch]' -print0 | \ - xargs -0 indent \ - --gnu-style \ - --format-first-column-comments \ - --indent-level4 \ - --brace-indent0 \ - --line-length100 \ - --no-tabs \ - --blank-lines-after-procedures - return $(git ls-files --modified | wc -l) -} - -( findUnindentedFiles "lib" && findUnindentedFiles "src" && findUnindentedFiles "tests" ) || { - echo "Sources not indented" - git ls-files --modified - exit 1 -} diff --git a/maint/utils/deploy-key.enc b/maint/utils/deploy-key.enc deleted file mode 100644 index 38f2c030942f3020b9deaa4924660e4a4b566e5a..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 1680 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 ak&(ZDhDMpmuSTK_6~=IS{}x?XrWha&&^h=3 diff --git a/maint/utils/deploy-key.pub b/maint/utils/deploy-key.pub deleted file mode 100644 index 07d77f9bf9..0000000000 --- a/maint/utils/deploy-key.pub +++ /dev/null @@ -1 +0,0 @@ -ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQDOpXSX8KMkqFPoXx4H+q0b9/taVceIoQu2QQQqqA/5MvlM0XD/YTBP2Nba235R+WSnC0F887+96xK7kx/48JrQeW5n+tle4Ot0NNfN0ON6pzhktshTk1YQUQfs5NDSXhBFXynTM9VgmXfFGxmG3nx+ym+hhN57IHnbwAQT5rk1cetaZNjoTVhEbVSzKJgqTQk1hUqRUuNFePPrXaMaqiWhaRl1gPYWQeNlqykT9p5tKgzbhO4lmwIGj+AUHOatTcp2qbgUElcUQuwd5Wt2CwvsM/8Pb1BUHHEl93qxERe4Nhxq98QOlqIoZa5gznIfw5iPXRpB9t5ijVL5qadWoNjn travis@midnight-commander.org diff --git a/maint/utils/travis-build.sh b/maint/utils/travis-build.sh deleted file mode 100755 index 92c5f9b75e..0000000000 --- a/maint/utils/travis-build.sh +++ /dev/null @@ -1,105 +0,0 @@ -#!/bin/bash -# -# Midnight Commander - build and test common configurations -# -# Copyright (C) 2015 -# The Free Software Foundation, Inc. -# -# Written by: -# Slava Zanko <slavazanko@gmail.com>, 2015 -# Yury V. Zaytsev <yury@shurup.com>, 2015 -# -# This file is part of the Midnight Commander. -# -# The Midnight Commander is free software: you can redistribute it -# and/or modify it under the terms of the GNU General Public License as -# published by the Free Software Foundation, either version 3 of the License, -# or (at your option) any later version. -# -# The Midnight Commander is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with this program. If not, see <http://www.gnu.org/licenses/>. - -set -e -set -x - -function do_build() { - make - make -k check - make install -} - -# Build distribution archive -mkdir -p distrib && cd $_ - -../configure -make dist-bzip2 - -DISTFILE=$(ls mc-*.tar.bz2) -DISTDIR=$(basename "$DISTFILE" .tar.bz2) - -tar -xjf $DISTFILE -cd $DISTDIR - -# Build default configuration (S-Lang) -mkdir -p build-default && pushd $_ - -../configure \ - --prefix="$(pwd)/INSTALL_ROOT" \ - --with-screen=slang \ - --enable-maintainer-mode \ - --enable-mclib \ - --enable-charset \ - --enable-aspell \ - --enable-tests \ - --enable-werror - -do_build - -popd - -# Build default configuration (ncurses) -mkdir -p build-ncurses && pushd $_ - -../configure \ - --prefix="$(pwd)/INSTALL_ROOT" \ - --with-screen=ncurses \ - --enable-maintainer-mode \ - --enable-mclib \ - --enable-charset \ - --enable-aspell \ - --enable-tests \ - --enable-werror - -do_build - -popd - -# Build all disabled -mkdir -p build-all-disabled && pushd $_ - -../configure \ - --prefix="$(pwd)/INSTALL_ROOT" \ - --disable-maintainer-mode \ - --disable-mclib \ - --disable-charset \ - --disable-aspell \ - --disable-largefile \ - --disable-nls \ - --disable-vfs \ - --disable-background \ - --without-x \ - --without-gpm-mouse \ - --without-internal-edit \ - --without-diff-viewer \ - --without-subshell \ - --enable-tests \ - --enable-werror - -do_build - -popd diff --git a/maint/utils/travis-deploy.sh b/maint/utils/travis-deploy.sh deleted file mode 100755 index 0c0c9742c5..0000000000 --- a/maint/utils/travis-deploy.sh +++ /dev/null @@ -1,71 +0,0 @@ -#!/bin/bash -# -# Midnight Commander - deployment script for Travis CI -# -# Copyright (C) 2016 -# The Free Software Foundation, Inc. -# -# Written by: -# Yury V. Zaytsev <yury@shurup.com>, 2016 -# -# This file is part of the Midnight Commander. -# -# The Midnight Commander is free software: you can redistribute it -# and/or modify it under the terms of the GNU General Public License as -# published by the Free Software Foundation, either version 3 of the License, -# or (at your option) any later version. -# -# The Midnight Commander is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with this program. If not, see <http://www.gnu.org/licenses/>. - -set -e -set -x - -GLOBAL_VERSION="6.5.7" -GLOBAL_URL="http://ftp.gnu.org/pub/gnu/global/global-${GLOBAL_VERSION}.tar.gz" -HTAGSFIX_URL="https://github.com/mooffie/htagsfix/raw/master/htagsfix" - -mkdir .global && pushd .global # ignored by GLOBAL's indexer - - wget ${GLOBAL_URL} - tar zxvf global-${GLOBAL_VERSION}.tar.gz > /dev/null 2>&1 - - pushd global-${GLOBAL_VERSION} - ./configure --prefix=$(pwd)/install > /dev/null 2>&1 - make > /dev/null 2>&1 - make install > /dev/null 2>&1 - popd - - export PATH="$(pwd)/global-${GLOBAL_VERSION}/install/bin:$PATH" - -popd - -gtags -v > /dev/null 2>&1 - -htags --suggest -t "Welcome to the Midnight Commander source tour!" > /dev/null 2>&1 - -wget --no-check-certificate ${HTAGSFIX_URL} - -ruby htagsfix > /dev/null 2>&1 - -cd HTML - -touch .nojekyll -echo "source.midnight-commander.org" > CNAME - -git init - -git config user.name "Travis CI" -git config user.email "travis@midnight-commander.org" - -git add . > /dev/null 2>&1 -git commit -m "Deploy to GitHub Pages" > /dev/null 2>&1 - -git push --force --quiet git@github.com:MidnightCommander/source.git master:gh-pages > /dev/null 2>&1 - -exit 0