Skip to content

curl/curl-www

master
Switch branches/tags

Name already in use

A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?
Code

Latest commit

It sets src on a <script> element which isn't allowed. It's probably
possible to change the script to do this safely, with fallback on
browsers that don't support Trusted Types, but it's not happening today.
e941730

Git stats

Files

Permalink
Failed to load latest commit information.
Type
Name
Latest commit message
Commit time
bug
June 21, 2021 09:18
dev
December 16, 2023 22:08
dl
December 22, 2023 13:46
October 30, 2023 09:53
November 22, 2023 15:34
May 25, 2023 14:54
December 6, 2023 08:20
June 26, 2003 13:05
September 27, 2023 09:19
November 7, 2016 10:03
November 4, 2020 13:49
December 6, 2023 08:20
October 22, 2016 00:21
November 4, 2020 13:49
June 11, 2015 08:39
November 4, 2020 13:49
November 4, 2020 13:49
September 10, 2023 12:18

curl-www

This is (most of) the curl.se web site contents. It mostly builds static HTML files that are preprocessed.

Prerequisites

The web site is a on old custom made setup that mostly builds static HTML files from a set of source files using (GNU) make. The sources files are preprocessed with what is basically a souped-up C preprocessor called fcpp and a set of perl scripts. The man pages get converted to HTML with roffit.

Markdown is converted to HTML with pandoc.

Make sure the following tools are in your $PATH.

  • curl
  • GNU date
  • GNU enscript
  • fcpp
  • GNU make
  • pandoc
  • perl (with CPAN packages: CGI, HTML::Entities)
  • roffit
  • zip

Build

Once you've cloned the Git repo the first time, invoke sh bootstrap.sh once to get a symlink and some some initial local files setup, and then you can build the web site locally by invoking make in the source root tree.

Note that this doesn't make you a complete web site mirror, as some scripts and files are only available on the real actual site, but should give you enough to let you load most HTML pages locally.

Edit the web

Web editing guidelines

curl.local

To run a local copy of the curl website, have a local Apache or python to serve curl.local on 127.0.0.1. Add this line to /etc/hosts:

127.0.0.1 curl.local

Apache httpd config

A config file for apache2 to run a virtual server for curl.local on your local machine might look like this:

<VirtualHost *:80>
    ServerName curl.local
    ServerAdmin [my email address]
    DocumentRoot [full path to the curl-www build]

    ErrorLog ${APACHE_LOG_DIR}/curllocal-error.log
    CustomLog ${APACHE_LOG_DIR}/curllocal-access.log combined
</VirtualHost>

<Directory [full path to the curl-www build]>
   Options Indexes Includes FollowSymLinks ExecCGI
   AllowOverride All
   AddHandler cgi-script .cgi
   Require all granted
</Directory>

Python3

From the directory containing the website, run:

python3 -m http.server --cgi -b curl.local 8000