Update the build infrastructure to use Git instead of Subversion

Summary:
The doc repository is not mirrored to Subversion so updating the
repository from Subversion does not make sense. Remove
Subversion-specific files too.

While here remove now defunct $FreeBSD$ markers in affected files.

Test Plan:
make clean
make update
make

Reviewed by:	bcr, ygy, doceng (gjb)
Differential Revision: https://reviews.freebsd.org/D27678
Subscribers:	drewery, emaste
This commit is contained in:
Rene Ladan 2020-12-19 12:33:43 +01:00
parent b62d4babfd
commit eaf07aef56
4 changed files with 8 additions and 109 deletions

View file

@ -1,5 +1,3 @@
# $FreeBSD$
#
# The user can override the default list of languages to build and install
# with the DOC_LANG variable.
#
@ -35,25 +33,19 @@ SUBDIR+= share
DOC_PREFIX?= ${.CURDIR}
.if exists(/usr/bin/svnlite)
SVN?= /usr/bin/svnlite
.elif exists(/usr/bin/svn)
SVN?= /usr/bin/svn
.else
SVN?= /usr/local/bin/svn
.endif
GIT?= /usr/local/bin/git
update:
.if !exists(${SVN})
.if !exists(${GIT})
@${ECHODIR} "--------------------------------------------------------------"
@${ECHODIR} ">>> ${SVN} is required to update ${.CURDIR}"
@${ECHODIR} ">>> ${GIT} is required to update ${.CURDIR}"
@${ECHODIR} "--------------------------------------------------------------"
@${EXIT}
.else
@${ECHODIR} "--------------------------------------------------------------"
@${ECHODIR} ">>> Updating ${.CURDIR} from svn repository"
@${ECHODIR} ">>> Updating ${.CURDIR} from git repository"
@${ECHODIR} "--------------------------------------------------------------"
cd ${.CURDIR}; ${SVN} update
cd ${.CURDIR}; ${GIT} pull --ff-only
.endif
.include "${DOC_PREFIX}/share/mk/doc.project.mk"

View file

@ -1,72 +0,0 @@
# Make sure you have a ~/.subversion/config. Simply using it (svn --help)
# will cause a default one to be created if you don't already have one.
# Add the following changes to ~/.subversion/config:
#
#
# Set:
# enable-auto-props = yes
#
#
# Append/edit auto-props section:
#
[auto-props]
*.c = svn:eol-style=native; svn:keywords=FreeBSD=%H; svn:mime-type=text/plain
*.h = svn:eol-style=native; svn:keywords=FreeBSD=%H; svn:mime-type=text/plain
*.s = svn:eol-style=native; svn:keywords=FreeBSD=%H; svn:mime-type=text/plain
*.S = svn:eol-style=native; svn:keywords=FreeBSD=%H; svn:mime-type=text/plain
*.cc = svn:eol-style=native; svn:keywords=FreeBSD=%H; svn:mime-type=text/plain
*.cpp = svn:eol-style=native; svn:keywords=FreeBSD=%H; svn:mime-type=text/plain
*.cxx = svn:eol-style=native; svn:keywords=FreeBSD=%H; svn:mime-type=text/plain
*.in = svn:eol-style=native; svn:keywords=FreeBSD=%H; svn:mime-type=text/plain
*.sh = svn:eol-style=native; svn:keywords=FreeBSD=%H; svn:mime-type=text/plain; svn:executable
*.pl = svn:eol-style=native; svn:keywords=FreeBSD=%H; svn:mime-type=text/plain; svn:executable
*.pm = svn:eol-style=native; svn:keywords=FreeBSD=%H; svn:mime-type=text/plain
*.py = svn:eol-style=native; svn:keywords=FreeBSD=%H; svn:mime-type=text/plain
*.rb = svn:eol-style=native; svn:keywords=FreeBSD=%H; svn:mime-type=text/plain
*.awk = svn:eol-style=native; svn:keywords=FreeBSD=%H; svn:mime-type=text/plain
*.sed = svn:eol-style=native; svn:keywords=FreeBSD=%H; svn:mime-type=text/plain
*.txt = svn:eol-style=native; svn:keywords=FreeBSD=%H; svn:mime-type=text/plain
*.log = svn:eol-style=native; svn:keywords=FreeBSD=%H; svn:mime-type=text/plain
*.conf = svn:eol-style=native; svn:keywords=FreeBSD=%H; svn:mime-type=text/plain
Makefile* = svn:eol-style=native; svn:keywords=FreeBSD=%H; svn:mime-type=text/plain
*.1 = svn:eol-style=native; svn:keywords=FreeBSD=%H; svn:mime-type=text/plain
*.2 = svn:eol-style=native; svn:keywords=FreeBSD=%H; svn:mime-type=text/plain
*.3 = svn:eol-style=native; svn:keywords=FreeBSD=%H; svn:mime-type=text/plain
*.4 = svn:eol-style=native; svn:keywords=FreeBSD=%H; svn:mime-type=text/plain
*.5 = svn:eol-style=native; svn:keywords=FreeBSD=%H; svn:mime-type=text/plain
*.6 = svn:eol-style=native; svn:keywords=FreeBSD=%H; svn:mime-type=text/plain
*.7 = svn:eol-style=native; svn:keywords=FreeBSD=%H; svn:mime-type=text/plain
*.8 = svn:eol-style=native; svn:keywords=FreeBSD=%H; svn:mime-type=text/plain
*.9 = svn:eol-style=native; svn:keywords=FreeBSD=%H; svn:mime-type=text/plain
*.css = svn:eol-style=native; svn:keywords=FreeBSD=%H; svn:mime-type=text/css
*.docbook = svn:eol-style=native; svn:keywords=FreeBSD=%H; svn:mime-type=text/sgml
*.dtd = svn:eol-style=native; svn:keywords=FreeBSD=%H; svn:mime-type=application/xml-dtd
*.ent = svn:eol-style=native; svn:keywords=FreeBSD=%H; svn:mime-type=application/xml-dtd
*.html = svn:eol-style=native; svn:keywords=FreeBSD=%H; svn:mime-type=text/html
*.mml = svn:eol-style=native; svn:keywords=FreeBSD=%H; svn:mime-type=application/mathml+xml
*.js = svn:eol-style=native; svn:keywords=FreeBSD=%H; svn:mime-type=application/javascript
*.rss = svn:eol-style=native; svn:keywords=FreeBSD=%H; svn:mime-type=application/rss+xml
*.sgml = svn:eol-style=native; svn:keywords=FreeBSD=%H; svn:mime-type=text/sgml
*.xhtml = svn:eol-style=native; svn:keywords=FreeBSD=%H; svn:mime-type=text/html+xml
*.xml = svn:eol-style=native; svn:keywords=FreeBSD=%H; svn:mime-type=text/xml
*.xsd = svn:eol-style=native; svn:keywords=FreeBSD=%H; svn:mime-type=text/xml
*.xsl = svn:eol-style=native; svn:keywords=FreeBSD=%H; svn:mime-type=application/xslt+xml
*.xslt = svn:eol-style=native; svn:keywords=FreeBSD=%H; svn:mime-type=application/xslt+xml
*.xul = svn:eol-style=native; svn:keywords=FreeBSD=%H; svn:mime-type=text/xul
*.bin = svn:mime-type=application/octet-stream
*.eps = svn:mime-type=application/postscript
*.exe = svn:mime-type=application/octet-stream
*.gz = svn:mime-type=application/gzip
*.pdf = svn:mime-type=application/pdf
*.ps = svn:mime-type=application/postscript
*.gif = svn:mime-type=image/gif
*.ico = svn:mime-type=image/vnd.microsoft.icon
*.jpeg = svn:mime-type=image/jpeg
*.jpg = svn:mime-type=image/jpeg
*.png = svn:mime-type=image/png
*.svg = svn:mime-type=image/svg+xml
*.tiff = svn:mime-type=image/tiff

View file

@ -1,6 +1,3 @@
#
# $FreeBSD$
#
# This include file <doc.docbook.mk> handles building and installing of
# DocBook documentation in the FreeBSD Documentation Project.
#
@ -99,25 +96,9 @@ LATESTREVISION!=cd ${.CURDIR} && ${GIT} log -1 --pretty=format:'\
--stringparam latestrevision.timestamp "%ci" \
--stringparam latestrevision.committer "%cn" \
--stringparam latestrevision.number "%h"' ${SRCS}
.else
# if using Subversion, get information from metadata
# rather than embedded version strings
.if exists(${DOC_PREFIX}/.svn) && exists(${SVN})
LATESTREVISION!=cd ${.CURDIR} && ${SVN} info ${SRCS} 2>/dev/null | \
${AWK} 'BEGIN { genfmt="--stringparam latestrevision."; \
timefmt=genfmt"timestamp \"%s %s\""; \
comtfmt=genfmt"committer \"%s\""; \
revnfmt=genfmt"number \"%u\""; \
fmt=timefmt" "comtfmt"\t\t"revnfmt"\n"; } \
/^Last Changed Author:/ { committer=$$4 } \
/^Last Changed Rev:/ { number=$$4 } \
/^Last Changed Date:/ { date=$$4; time=$$5; \
printf(fmt, date, time, committer, number) }' \
| ${SORT} | ${TAIL} -n1
.endif
.endif
# if neither Subversion nor Git revision numbers are available, use
# If the Git revision number is not available, use
# the revision date from the timestamp of the most recent file and
# set the revision number to "filedate"
.if empty(LATESTREVISION)

View file

@ -2,7 +2,7 @@
# Copyright (c) 2001-2017 Wolfram Schneider <wosch@FreeBSD.org>
# Copyright (c) 2001 Dima Dorfman <dd@FreeBSD.org>
#
# Update the FreeBSD web site from the SVN repository.
# Update the FreeBSD web site from the Git repository.
#
#
# NOTE: Changes to this file is NOT automatically used for the web
@ -24,7 +24,7 @@
# INSTARGS - Arguments to pass to make(1) when installing.
# WEBMAILTO - Address to send mail to if the build fails.
#
# subtrees - List of directores in $BUILDDIR which are from SVN.
# subtrees - List of directories in $BUILDDIR which are from VCS.
#
# Variables which are in uppercase are derived from the environment
# unless they don't exist, in which case a value suitable for
@ -39,8 +39,6 @@
# 2 - failure in VCS operations
# 3 - failure in make operations
#
# $FreeBSD$
#
#
# Default configuration.