web:mirror
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
web:mirror [2012/06/05 11:03] – use git bjori | web:mirror [2024/07/21 00:07] (current) – jimw | ||
---|---|---|---|
Line 1: | Line 1: | ||
+ | ==== Setting up phpweb for local development ==== | ||
+ | |||
+ | See [[https:// | ||
+ | |||
+ | Alternatively, | ||
+ | |||
==== How to create a PHP.net mirror ==== | ==== How to create a PHP.net mirror ==== | ||
- | Setting up an official (or unofficial) mirror is described within [[http:// | + | Setting up an unofficial mirror is described within [[http:// |
- | === I'm lazy. Just give me something | + | === Quick Script |
- | Save the following shell script as IcanHazPHPWeb.sh | + | |
- | Then execute | + | Save the following shell script as '' |
- | And wait for ca 10 minutes. | + | Then execute |
+ | |||
+ | And wait for ca 10 minutes. | ||
<code shell> | <code shell> | ||
Line 13: | Line 21: | ||
cd ~/php.net | cd ~/php.net | ||
+ | # Checkout the manual base sources | ||
+ | git clone https:// | ||
# Checkout the english manual sources | # Checkout the english manual sources | ||
- | svn co https://svn.php.net/repository/phpdoc/modules/doc-en | + | git clone https://github.com/php/doc-en.git en |
+ | # Checkout PHD to build documentation | ||
+ | git clone https://github.com/php/phd.git phd | ||
# Checkout the actual website (does not include / | # Checkout the actual website (does not include / | ||
- | git clone git://git.php.net/web/php.git phpweb | + | git clone https://github.com/php/web-php.git phpweb |
cd phpweb | cd phpweb | ||
# Some files are pre-generated on master.php.net for various reasons | # Some files are pre-generated on master.php.net for various reasons | ||
- | (cd include && for i in countries.inc last_updated.inc mirrors.inc pregen-confs.inc pregen-events.inc pregen-news.inc; | + | (cd include && for i in countries.inc last_updated.inc mirrors.inc pregen-confs.inc pregen-events.inc pregen-news.inc; |
- | (cd backend && for i in ip-to-country.db ip-to-country.idx; | + | (cd backend && for i in ip-to-country.db ip-to-country.idx; |
cd .. | cd .. | ||
# Install PhD and build the manual | # Install PhD and build the manual | ||
- | cd doc-en | ||
php doc-base/ | php doc-base/ | ||
- | pear install doc.php.net/ | + | php -dmemory_limit=2G phd/render.php --docbook |
- | phd -d doc-base/ | + | |
- | cd .. | + | |
cd phpweb | cd phpweb | ||
# Symlink the generated english documentations from our PhD build dir | # Symlink the generated english documentations from our PhD build dir | ||
- | (cd manual && ln -s ~/php.net/doc-en/ | + | rm -rf manual/en |
+ | (cd manual && ln -s `pwd`/../../ | ||
- | echo "Now copy& | + | php -S localhost: |
- | echo "Fill out the ' | + | |
</ | </ | ||
- | Note: To see the "new look", add ?beta=1 after the url, or enable the cookie from /my.php | ||
- | |||
- | |||
- | === The SVN way, but with a hack === | ||
- | |||
- | - Checkout phpweb (svn co https:// | ||
- | - Within phpweb, run this: <code php> | ||
- | <?php | ||
- | // Note: This is a complete hack | ||
- | // Mirror to steal from | ||
- | $mirror = ' | ||
- | |||
- | // Files phpweb needs (typically from rsync box) | ||
- | $files = array(' | ||
- | |||
- | foreach ($files as $file) { | ||
- | file_put_contents($file, | ||
- | } | ||
- | |||
- | // Another required file, let's create it ourselves | ||
- | file_put_contents(' | ||
- | ?> | ||
- | </ | ||
- | - Make a virtual host, see [[http:// | ||
- | - If wanting the PHP Manual too, either: | ||
- | * [[doc: | ||
- | * Rsync it | ||
- | * Download it |
web/mirror.1338894195.txt.gz · Last modified: 2017/09/22 13:28 (external edit)