Skip to content

Commit

Permalink
remove obsolete mirroring functionality (w3f#3512)
Browse files Browse the repository at this point in the history
  • Loading branch information
alfarok authored Jul 14, 2022
1 parent fd00215 commit 525aac8
Show file tree
Hide file tree
Showing 150 changed files with 181 additions and 369 deletions.
1 change: 0 additions & 1 deletion .github/workflows/generate-pdf.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@ jobs:
- name: Clone and run the site
run: |
yarn
yarn mirror
yarn polkadot:start &
while ! nc -z localhost 3000; do
sleep 1
Expand Down
1 change: 0 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,6 @@ typings/
polkadot-wiki/build
kusama-guide/build
build-script*
**/mirror*.md
.DS_Store
kusama-guide/translated_docs/
polkadot-wiki/translated-docs/
Expand Down
18 changes: 0 additions & 18 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@
- [Static Site Generator](#static-site-generator)
- [Search Engine](#search-engine)
- [Automated Deployments](#automated-deployments)
- [Mirror Pages](#mirror-pages)
- [Conditional Rendering](#conditional-rendering)
- [Internationalization](#internationalization)
- [License](#license)
Expand Down Expand Up @@ -179,23 +178,6 @@ new commits on `master` are transferred into the production branch,`prod`, by re
production workflow will deploy `prod` to the public sites: [Polkadot Wiki](https://wiki.polkadot.network) and
[Kusama Guide](https://guide.kusama.network), respectively.

### Mirror Pages

A limitation of Docusaurus is that pages can only be included in one sidebar at any given time.
Thus, our Kusama section will either hijack some content it shares with the rest of the Wiki or
lack that content. The repository mirrors some pages and includes them in additional sidebars to solve this.

The `scripts` folder contains a `mirror.js` script that creates a copy of the pages to duplicate across
sidebars. The new pages are prefixed with `mirror` and must first be declared in `mirror.js`, then added
to the relevant sidebar section. To run the script:

```bash
yarn mirror
```

> Note: This command runs when using `polkadot:start` or `kusama:start` development
> scripts, so you don't need to worry about running it manually if you start the development site
> with one of these commands.

### Conditional Rendering

Expand Down
4 changes: 2 additions & 2 deletions docs/build/build-parachains.md
Original file line number Diff line number Diff line change
Expand Up @@ -476,7 +476,7 @@ you will need to acquire a parachain slot.

Parachain slots will be sold in open auctions, the mechanics of which can be found on the
{{ polkadot: [parachain auction](../learn/learn-auction.md) :polkadot }}
{{ kusama: [parachain auction](../learn/mirror-learn-auction.md) :kusama }} page of the wiki.
{{ kusama: [parachain auction](../learn/learn-auction.md) :kusama }} page of the wiki.

### Parathread

Expand All @@ -487,7 +487,7 @@ transition into a Relay Chain.

For more information on how parathread per-block auctions work, see the more detailed
{{ polkadot: [parathread](../learn/learn-parathreads.md) :polkadot }}
{{ kusama: [parathread](../learn/mirror-learn-parathreads.md) :kusama }} page.
{{ kusama: [parathread](../learn/learn-parathreads.md) :kusama }} page.

## Resources

Expand Down
4 changes: 2 additions & 2 deletions docs/general/grants.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,8 @@ Polkadot and Kusama offer everyone the opportunity to apply for funding via the
Due to high demand and spamming issues, the Kusama faucet is no longer in operation. The Web3 Foundation has considered new ways to distribute KSM for people who need KSM to build.

If you are interested in obtaining KSM for building or research, you can apply through the
[Treasury](../learn/mirror-learn-treasury.md#creating-a-treasury-proposal) or receive a
[tip](../learn/mirror-learn-treasury.md#tipping) for doing something cool in the community.
[Treasury](../learn/learn-treasury.md#creating-a-treasury-proposal) or receive a
[tip](../learn/learn-treasury.md#tipping) for doing something cool in the community.

:::

Expand Down
4 changes: 2 additions & 2 deletions docs/general/kusama/kusama-getting-started.md
Original file line number Diff line number Diff line change
Expand Up @@ -205,6 +205,6 @@ Additional Resources:
- [claims](kusama-claims)
- [endpoints](maintain-endpoints)
- [tokens](https://claim.kusama.network/)
- [validator](../../maintain/kusama/mirror-maintain-guides-how-to-validate-kusama.md)
- [nominator](../../maintain/kusama/mirror-maintain-guides-how-to-nominate-kusama.md)
- [validator](../../maintain/kusama/maintain-guides-how-to-validate-kusama.md)
- [nominator](../../maintain/kusama/maintain-guides-how-to-nominate-kusama.md)
- [polkadot wiki](https://wiki.polkadot.network/)
2 changes: 1 addition & 1 deletion docs/general/thousand-validators.md
Original file line number Diff line number Diff line change
Expand Up @@ -131,4 +131,4 @@ Since approximately early January 2021, the nominators will select an automatic
[leaderboard]: https://thousand-validators.kusama.network/#/leaderboard
[kusama 1kv form]: https://forms.gle/xqYLoceTwg1qvc9i6
[polkadot 1kv form]: https://docs.google.com/forms/d/e/1FAIpQLSdS-alI-J2wgIRCQVjQC7ZbFiTnf36hYBdmO-1ARMjKbC7H9w/viewform
[identity instructions]: ../learn/mirror-learn-identity.md#setting-an-identity
[identity instructions]: ../learn/learn-identity.md#setting-an-identity
2 changes: 1 addition & 1 deletion docs/learn/learn-common-good-chains.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ as a whole. By allocating a subset of parachain slots to common good chains, the
realize the benefit of valuable parachains that would otherwise be underfunded due to the free-rider
problem. They are not allocated via the parachain auction process but by the on-chain
{{ polkadot: [governance](learn-governance.md) :polkadot }}
{{ kusama: [governance](mirror-learn-governance.md) :kusama }} system. Generally, a common good
{{ kusama: [governance](learn-governance.md) :kusama }} system. Generally, a common good
parachain's lease would not expire; it would only be removed via governance.

The purpose of these parachains will probably fall into one of two categories: system level chains
Expand Down
4 changes: 2 additions & 2 deletions docs/learn/learn-crowdloans.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ contribute for a crowdloan, watch the video below or read this [support article
:::note Testing on Rococo

For information on how to participate in the crowdloan and parachain auction testing on
Rococo, please see the {{ polkadot: [Rococo content](../build/build-parachains.md##testing-a-parachains:-rococo-testnet) :polkadot }}{{ kusama: [Rococo content](../build/mirror-build-parachains.md##testing-a-parachains:-rococo-testnet) :kusama }}.
Rococo, please see the {{ polkadot: [Rococo content](../build/build-parachains.md##testing-a-parachains:-rococo-testnet) :polkadot }}{{ kusama: [Rococo content](../build/build-parachains.md##testing-a-parachains:-rococo-testnet) :kusama }}.

:::

Expand All @@ -31,7 +31,7 @@ Rococo, please see the {{ polkadot: [Rococo content](../build/build-parachains.m
Anyone who has registered a parachain can create a new crowdloan campaign for a slot
by depositing a specified number of tokens. A campaign is configured as a
range of slots (i.e. the duration of the {{ polkadot: [parachain](learn-parachains.md) :polkadot }}
{{ kusama: [parachain](mirror-learn-parachains.md) :kusama }} will bid for), a cap, and a duration.
{{ kusama: [parachain](learn-parachains.md) :kusama }} will bid for), a cap, and a duration.
The duration can last over several auctions, meaning that the team will not need to restart the
campaign just because they do not secure a slot on their first attempt.

Expand Down
16 changes: 8 additions & 8 deletions docs/learn/learn-parachains.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ slug: ../learn-parachains

For information on how to participate in the crowdloan and parachain auction testing on
Rococo, please see the
{{ polkadot: [Rococo Content](../build/build-parachains.md##testing-a-parachains:-rococo-testnet) :polkadot }}{{ kusama: [Rococo Content](../build/mirror-build-parachains.md##testing-a-parachains:-rococo-testnet) :kusama }} on the parachain development guide.
{{ polkadot: [Rococo Content](../build/build-parachains.md##testing-a-parachains:-rococo-testnet) :polkadot }}{{ kusama: [Rococo Content](../build/build-parachains.md##testing-a-parachains:-rococo-testnet) :kusama }} on the parachain development guide.

:::

Expand Down Expand Up @@ -103,20 +103,20 @@ several ways to allocate them:

["Common Good" parachains](#common-good-parachains) are allocated by Polkadot's on-chain
{{ polkadot: [governance](learn-governance.md) :polkadot }}
{{ kusama: [governance](mirror-learn-governance.md) :kusama }} system, and are deemed as a "common
{{ kusama: [governance](learn-governance.md) :kusama }} system, and are deemed as a "common
good" for the network, such as bridges to other networks or chains. They are usually considered
system-level chains or public utility chains. These typically do not have an economic model and help
remove transactions from the Relay Chain, allowing for more efficient parachain processing.

{{ polkadot: [Auction granted parachains](learn-auction.md) :polkadot }}
{{ kusama: [Auction granted parachains](mirror-learn-auction.md) :kusama }} are granted in a
{{ kusama: [Auction granted parachains](learn-auction.md) :kusama }} are granted in a
permissionless auction. Parachain teams can either bid with their own DOT tokens, or source them
from the community using the
{{ polkadot: [crowdloan functionality](learn-crowdloans.md) :polkadot }}
{{ kusama: [crowdloan functionality](mirror-learn-crowdloans.md) :kusama }}.
{{ kusama: [crowdloan functionality](learn-crowdloans.md) :kusama }}.

{{ polkadot: [Parathreads](learn-parathreads.md) :polkadot }}
{{ kusama: [Parathreads](mirror-learn-parathreads.md) :kusama }} have the same API as parachains,
{{ kusama: [Parathreads](learn-parathreads.md) :kusama }} have the same API as parachains,
but are scheduled for execution on a pay-as-you-go basis with an auction for each block.

### Slot Expiration
Expand All @@ -133,7 +133,7 @@ ecosystem as a whole. By allocating a subset of parachain slots to common good c
network can realize the benefit of valuable parachains that would otherwise be underfunded due to
the free-rider problem. They are not allocated via the parachain auction process but by the
on-chain {{ polkadot: [governance](learn-governance.md) :polkadot }}
{{ kusama: [governance](mirror-learn-governance.md) :kusama }} system. Generally, a common good
{{ kusama: [governance](learn-governance.md) :kusama }} system. Generally, a common good
parachain's lease would not expire; it would only be removed via governance.

See the
Expand Down Expand Up @@ -186,10 +186,10 @@ is not Substrate-based.

Parachain slots will be acquirable through auction, please see the
{{ polkadot: [parachain slots](learn-auction.md) :polkadot }}
{{ kusama: [parachain slots](mirror-learn-auction.md) :kusama }} article. Additionally, some
{{ kusama: [parachain slots](learn-auction.md) :kusama }} article. Additionally, some
parachain slots will be set aside to run
{{ polkadot: [parathreads](learn-parathreads.md) :polkadot }}
{{ kusama: [parathreads](mirror-learn-parathreads.md) :kusama }} — chains that bid on a
{{ kusama: [parathreads](learn-parathreads.md) :kusama }} — chains that bid on a
per-block basis to be included in the Relay Chain.

### What happens to parachains when the number of validators drops below a certain threshold?
Expand Down
2 changes: 1 addition & 1 deletion docs/maintain/maintain-guides-how-to-validate-polkadot.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ slug: ../maintain-guides-how-to-validate-polkadot

:::info

The following information applies to the Polkadot network. If you want to set up a validator on Kusama, check out the [Kusama guide](kusama/mirror-maintain-guides-how-to-validate-kusama.md) instead.
The following information applies to the Polkadot network. If you want to set up a validator on Kusama, check out the [Kusama guide](kusama/maintain-guides-how-to-validate-kusama.md) instead.

This guide will instruct you how to set up a validator node on the Polkadot network.

Expand Down
4 changes: 0 additions & 4 deletions kusama-guide/docusaurus.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -48,10 +48,6 @@ module.exports = {
docs: {
showLastUpdateAuthor: true,
showLastUpdateTime: true,
editUrl: ({ docPath }) => {
const githubDocPath = `https://github.com/w3f/polkadot-wiki/edit/master/docs/`;
return githubDocPath + docPath.replace("mirror-", "");
},
path: "../docs",
sidebarPath: "./sidebars.js",
remarkPlugins: [injectPlugin({ isPolkadot: false })],
Expand Down
5 changes: 2 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"scripts": {
"kusama:clean": "shx rm -rf node_modules/.cache; docusaurus clear kusama-guide",
"kusama:start": "yarn fetch --isPolkadot=false; docusaurus start kusama-guide",
"prekusama:build": "npm-run-all -ln kusama:clean -p \"fetch --isPolkadot=false\" mirror kusama:copy-assets --aggregate-output",
"prekusama:build": "npm-run-all -ln kusama:clean -p \"fetch --isPolkadot=false\" kusama:copy-assets --aggregate-output",
"kusama:build": "cross-env BUILDING=true docusaurus build kusama-guide; node kusama-guide/postprocess",
"kusama:publish-gh-pages": "cross-env PUBLISHING=true docusaurus deploy kusama-guide",
"kusama:copy-assets": "shx mkdir -p kusama-guide/i18n/zh-CN/docusaurus-plugin-content-docs/current",
Expand All @@ -11,7 +11,7 @@
"kusama:pdf": "yarn pdf --initialDocURLs \"http://localhost:3000/docs/kusama-index\" --outputPDFFilename=\"kusama-guide/static/kusama-wiki.pdf\" --coverTitle=\"KUSAMA GUIDE\"",
"polkadot:clean": "shx rm -rf node_modules/.cache; docusaurus clear polkadot-wiki",
"polkadot:start": "yarn fetch; docusaurus start polkadot-wiki",
"prepolkadot:build": "npm-run-all -ln polkadot:clean -p fetch mirror polkadot:copy-assets:* --aggregate-output",
"prepolkadot:build": "npm-run-all -ln polkadot:clean -p fetch polkadot:copy-assets:* --aggregate-output",
"polkadot:build": "cross-env BUILDING=true docusaurus build polkadot-wiki; node polkadot-wiki/postprocess",
"polkadot:publish-gh-pages": "cross-env PUBLISHING=true docusaurus deploy polkadot-wiki",
"polkadot:pdf": "yarn pdf --initialDocURLs \"http://localhost:3000/docs/getting-started\" --outputPDFFilename=\"polkadot-wiki/static/polkadot-wiki.pdf\" --coverTitle=\"POLKADOT WIKI\"",
Expand All @@ -30,7 +30,6 @@
"polkadot:copy-assets:zh-CN": "shx mkdir -p polkadot-wiki/i18n/zh-CN/docusaurus-plugin-content-docs/current; shx cp -R docs/assets polkadot-wiki/i18n/zh-CN/docusaurus-plugin-content-docs/current",
"pdf": "npx mr-pdf --contentSelector=\"article\" --paginationSelector=\".pagination-nav__item--next > a\" --pdfFormat=\"A4\" --pdfMargin=\"90,60,80,60\"",
"fetch": "node scripts/fetch.mjs --isPolkadot",
"mirror": "node --experimental-json-modules scripts/mirror.mjs",
"crowdin": "crowdin",
"docusaurus": "docusaurus",
"prepare": "husky install"
Expand Down
2 changes: 1 addition & 1 deletion polkadot-wiki/translated_docs/ar/kusama-faucet.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,4 +6,4 @@ sidebar_label: Faucet

The Kusama faucet that once was available is no longer in operation.

If you are interested in obtaining KSM for building or research, you can apply through the [Treasury](mirror-learn-treasury#creating-a-treasury-proposal) or receive a [tip](mirror-learn-treasury#tipping) for doing something cool in the community.
If you are interested in obtaining KSM for building or research, you can apply through the [Treasury](learn-treasury#creating-a-treasury-proposal) or receive a [tip](learn-treasury#tipping) for doing something cool in the community.
4 changes: 2 additions & 2 deletions polkadot-wiki/translated_docs/ar/kusama-getting-started.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ While Kusama does not support smart contracts natively, building apps on it is s
[create-account]: kusama-claims
[endpoints]: kusama-endpoints
[tokens]: https://claim.kusama.network/
[validator]: mirror-maintain-guides-how-to-validate-kusama
[nominator]: mirror-maintain-guides-how-to-nominate-kusama
[validator]: maintain-guides-how-to-validate-kusama
[nominator]: maintain-guides-how-to-nominate-kusama
[polkadot wiki]: https://wiki.polkadot.network/
[polkadot-builders]: https://wiki.polkadot.network/docs/en/build-index
2 changes: 1 addition & 1 deletion polkadot-wiki/translated_docs/ar/learn-staking.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ In staking, you can be either a [nominator or a validator](#validators-and-nomin

As a nominator, you can nominate one or more (up to 16) validator candidates that you trust to help you earn rewards in DOT. You can take a look at the [nominator guide](learn-nominator) to understand what you are required to do when the mainnet launches.

A validator node is required to be responsive 24/7, perform its expected duties in a timely manner, and avoid any slashable behavior. You can follow our [Kusama validator guide](https://guide.kusama.network/docs/en/mirror-maintain-guides-how-to-validate-kusama) if you would like to run a validator on Kusama.
A validator node is required to be responsive 24/7, perform its expected duties in a timely manner, and avoid any slashable behavior. You can follow our [Kusama validator guide](https://guide.kusama.network/docs/en/maintain-guides-how-to-validate-kusama) if you would like to run a validator on Kusama.

### 2. Nomination period

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ title: How to Nominate on Polkadot
sidebar_label: How to Nominate on Polkadot
---

> The following information applies to the Polkadot network. If you want to nominate on Kusama, check out the [Kusama guide](https://guide.kusama.network/docs/en/mirror-maintain-guides-how-to-nominate-kusama) instead.
> The following information applies to the Polkadot network. If you want to nominate on Kusama, check out the [Kusama guide](https://guide.kusama.network/docs/en/maintain-guides-how-to-nominate-kusama) instead.
Nominators are one type of participant in the staking subsystem of Polkadot. They are responsible for appointing their stake to the validators who are the second type of participant. By appointing their stake, they are able to elect the active set of validators and share in the rewards that are paid out.

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ title: Run a Validator (Polkadot)
sidebar_label: How to run a Validator on Polkadot
---

> The following information applies to the Polkadot network. If you want to set up a validator on Kusama, check out the [Kusama guide](https://guide.kusama.network/docs/en/mirror-maintain-guides-how-to-validate-kusama) instead.
> The following information applies to the Polkadot network. If you want to set up a validator on Kusama, check out the [Kusama guide](https://guide.kusama.network/docs/en/maintain-guides-how-to-validate-kusama) instead.
This guide will instruct you how to set up a validator node on the Polkadot network.

Expand Down
2 changes: 1 addition & 1 deletion polkadot-wiki/translated_docs/ar/thousand-validators.md
Original file line number Diff line number Diff line change
Expand Up @@ -81,6 +81,6 @@ The below addresses are the stash / controller pairs for the nominators involved
A time delay proxy is used as the main interaction method for all of these accounts.

Since approximately early January 2021, the nominators will select an automatic number of validators to nominate based on the lowest amount staked for a validator and the amount of funds it holds. This can be anywhere from a few validators receiving nomination from a single nominator to the max of 16.
https://docs.google.com/forms/d/e/1FAIpQLSdS-alI-J2wgIRCQVjQC7ZbFiTnf36hYBdmO-1ARMjKbC7H9w/viewform https://guide.kusama.network/docs/en/mirror-learn-identity#setting-an-identity
https://docs.google.com/forms/d/e/1FAIpQLSdS-alI-J2wgIRCQVjQC7ZbFiTnf36hYBdmO-1ARMjKbC7H9w/viewform https://guide.kusama.network/docs/en/learn-identity#setting-an-identity

[kusama 1kv form]: https://forms.gle/xqYLoceTwg1qvc9i6
2 changes: 1 addition & 1 deletion polkadot-wiki/translated_docs/de/kusama-faucet.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,4 +6,4 @@ sidebar_label: Faucet

The Kusama faucet that once was available is no longer in operation.

If you are interested in obtaining KSM for building or research, you can apply through the [Treasury](mirror-learn-treasury#creating-a-treasury-proposal) or receive a [tip](mirror-learn-treasury#tipping) for doing something cool in the community.
If you are interested in obtaining KSM for building or research, you can apply through the [Treasury](learn-treasury#creating-a-treasury-proposal) or receive a [tip](learn-treasury#tipping) for doing something cool in the community.
4 changes: 2 additions & 2 deletions polkadot-wiki/translated_docs/de/kusama-getting-started.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ While Kusama does not support smart contracts natively, building apps on it is s
[create-account]: kusama-claims
[endpoints]: kusama-endpoints
[tokens]: https://claim.kusama.network/
[validator]: mirror-maintain-guides-how-to-validate-kusama
[nominator]: mirror-maintain-guides-how-to-nominate-kusama
[validator]: maintain-guides-how-to-validate-kusama
[nominator]: maintain-guides-how-to-nominate-kusama
[polkadot wiki]: https://wiki.polkadot.network/
[polkadot-builders]: https://wiki.polkadot.network/docs/en/build-index
Loading

0 comments on commit 525aac8

Please sign in to comment.