Skip to content

First stab at a prototype for revamping the download instructions page #1287

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 20 commits into from
Closed
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 6 additions & 6 deletions include/download-instructions/linux-debian-cli-community.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,11 @@
On the command line, run the following commands:
</p>
<pre><code class="language-bash line-numbers">
sudo apt-get update
sudo apt-get install -y lsb-release ca-certificates apt-transport-https curl
sudo curl -sSLo /tmp/debsuryorg-archive-keyring.deb https://packages.sury.org/debsuryorg-archive-keyring.deb
sudo dpkg -i /tmp/debsuryorg-archive-keyring.deb
sudo sh -c 'echo "deb [signed-by=/usr/share/keyrings/debsuryorg-archive-keyring.gpg] https://packages.sury.org/php/ $(lsb_release -sc) main" &gt; /etc/apt/sources.list.d/php.list'
sudo apt-get update
# Add the packages.sury.org/php repository.
sudo apt update
sudo apt install -y curl
curl -sSL https://packages.sury.org/php/README.txt | sudo bash -x

# Install PHP.
sudo apt-get install -y php<?= $version; ?>
</code></pre>
3 changes: 3 additions & 0 deletions include/download-instructions/linux-debian-cli-default.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,9 @@
On the command line, run the following commands:
</p>
<pre><code class="language-bash line-numbers">
# Update the package lists.
sudo apt update

# Install PHP.
sudo apt install -y php
</code></pre>
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,12 @@
On the command line, run the following commands:
</p>
<pre><code class="language-bash line-numbers">
# Add the Remi's RPM repository.
sudo dnf install -y dnf-plugins-core
sudo dnf install -y https://rpms.remirepo.net/fedora/remi-release-$(rpm -E %fedora).rpm
sudo dnf module reset php -y
sudo dnf module enable php:remi-<?= $version; ?> -y

# Install PHP.
sudo dnf install -y php
</code></pre>
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,6 @@
On the command line, run the following commands:
</p>
<pre><code class="language-bash line-numbers">
# Install PHP.
sudo dnf install -y php
</code></pre>
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,12 @@
On the command line, run the following commands:
</p>
<pre><code class="language-bash line-numbers">
# Add the ondrej/php repository.
sudo apt update
sudo apt install -y software-properties-common
sudo add-apt-repository ppa:ondrej/php -y
sudo LC_ALL=C.UTF-8 add-apt-repository ppa:ondrej/php -y
sudo apt update

# Install PHP.
sudo apt install -y php<?= $version; ?>
</code></pre>
3 changes: 3 additions & 0 deletions include/download-instructions/linux-ubuntu-cli-default.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,9 @@
On the command line, run the following commands:
</p>
<pre><code class="language-bash line-numbers">
# Update the package lists.
sudo apt update

# Install PHP.
sudo apt install -y php
</code></pre>
7 changes: 5 additions & 2 deletions include/download-instructions/osx-homebrew-php.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,11 @@
On the command line, run the following commands:
</p>
<pre><code class="language-bash line-numbers">
brew tap shivammathur/php
brew install php@<?= $version; ?>
# Download and install Homebrew.
curl -o- https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh | bash

# Install and link PHP.
brew install shivammathur/php/php@<?= $version; ?>

brew link --force --overwrite php@<?= $version; ?>
</code></pre>
4 changes: 4 additions & 0 deletions include/download-instructions/osx-homebrew.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,10 @@
On the command line, run the following commands:
</p>
<pre><code class="language-bash line-numbers">
# Download and install Homebrew.
curl -o- https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh | bash

# Install and link PHP.
brew install php@<?= $version; ?>

brew link --force --overwrite php@<?= $version; ?>
Expand Down
1 change: 1 addition & 0 deletions include/download-instructions/osx-macports.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,6 @@
On the command line, run the following commands:
</p>
<pre><code class="language-bash line-numbers">
# Please refer to https://guide.macports.org/chunked/installing.macports.html for installing MacPorts.
sudo port install php<?= $versionNoDot; ?>
</code></pre>
4 changes: 4 additions & 0 deletions include/download-instructions/windows-chocolatey.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,9 @@
On the command line, run the following commands:
</p>
<pre><code class="language-powershell line-numbers">
# Download and install Chocolatey.
powershell -c "irm https://community.chocolatey.org/install.ps1|iex"

# Download and install PHP.
choco install php --version=<?= $version; ?> -y
</code></pre>
1 change: 1 addition & 0 deletions include/download-instructions/windows-native.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,6 @@
On the command line, run the following commands:
</p>
<pre><code class="language-powershell line-numbers">
# Download and install PHP.
powershell -c "& ([ScriptBlock]::Create((irm 'https://php.net/install/windows.ps1'))) -Version <?= $version; ?>"
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should be https://www.php.net/install/windows.ps1 to avoid redirects. I'm also thinking that instead of install, the directory should be include/download-instructions, like the other files.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've fixed the domain part of this now.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, we can change the directory to include/download-instructions, my thought on adding the install directory was it will be short and would have recall value.

</code></pre>
7 changes: 6 additions & 1 deletion include/download-instructions/windows-scoop.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,10 @@
On the command line, run the following commands:
</p>
<pre><code class="language-powershell line-numbers">
scoop install php@<?= $version; ?>
# Download and install Scoop.
powershell -c "irm https://get.scoop.sh | iex"

# Download and install PHP.
scoop bucket add versions
scoop install php<?= $versionNoDot; ?>
</code></pre>