docs: Use relative links for files outside the docs/ directory

Use javascript to fixup the "github pages" rendering of links to files
outside the docs/ directory.  Then use normal relative links in the
documentation.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
This commit is contained in:
Kevin O'Connor 2020-12-03 15:06:58 -05:00
parent a2d1e03b91
commit 1f2d9c051c
7 changed files with 58 additions and 64 deletions

View File

@ -122,9 +122,8 @@ position_max:
## Cartesian Kinematics
See
[example-cartesian.cfg](https://github.com/KevinOConnor/klipper/tree/master/config/example-cartesian.cfg)
for an example cartesian kinematics config file.
See [example-cartesian.cfg](../config/example-cartesian.cfg) for an
example cartesian kinematics config file.
Only parameters specific to cartesian printers are described here -
see [common kinematic settings](#common-kinematic-settings) for
@ -158,9 +157,8 @@ max_z_accel:
## Linear Delta Kinematics
See
[example-delta.cfg](https://github.com/KevinOConnor/klipper/tree/master/config/example-delta.cfg)
for an example linear delta kinematics config file. See the
See [example-delta.cfg](../config/example-delta.cfg) for an example
linear delta kinematics config file. See the
[delta calibrate guide](Delta_Calibrate.md) for information on
calibration.
@ -240,9 +238,8 @@ radius:
## CoreXY Kinematics
See
[example-corexy.cfg](https://github.com/KevinOConnor/klipper/tree/master/config/example-corexy.cfg)
for an example corexy (and h-bot) kinematics file.
See [example-corexy.cfg](../config/example-corexy.cfg) for an example
corexy (and h-bot) kinematics file.
Only parameters specific to corexy printers are described here - see
[common kinematic settings](#common-kinematic-settings) for available
@ -276,9 +273,8 @@ max_z_accel:
## CoreXZ Kinematics
See
[example-corexz.cfg](https://github.com/KevinOConnor/klipper/tree/master/config/example-corexz.cfg)
for an example corexz kinematics config file.
See [example-corexz.cfg](../config/example-corexz.cfg) for an example
corexz kinematics config file.
Only parameters specific to corexz printers are described here - see
[common kinematic settings](#common-kinematic-settings) for available
@ -309,9 +305,8 @@ max_z_accel:
## Polar Kinematics
See
[example-polar.cfg](https://github.com/KevinOConnor/klipper/tree/master/config/example-polar.cfg)
for an example polar kinematics config file.
See [example-polar.cfg](../config/example-polar.cfg) for an example
polar kinematics config file.
Only parameters specific to polar printers are described here - see
[common kinematic settings](#common-kinematic-settings) for available
@ -353,9 +348,8 @@ max_z_accel:
## Rotary delta Kinematics
See
[example-rotary-delta.cfg](https://github.com/KevinOConnor/klipper/tree/master/config/example-rotary-delta.cfg)
for an example rotary delta kinematics config file.
See [example-rotary-delta.cfg](../config/example-rotary-delta.cfg) for
an example rotary delta kinematics config file.
Only parameters specific to rotary delta printers are described here -
see [common kinematic settings](#common-kinematic-settings) for
@ -442,9 +436,8 @@ radius:
## Cable winch Kinematics
See the
[example-winch.cfg](https://github.com/KevinOConnor/klipper/tree/master/config/example-winch.cfg)
for an example cable winch kinematics config file.
See the [example-winch.cfg](../config/example-winch.cfg) for an
example cable winch kinematics config file.
Only parameters specific to cable winch printers are described here -
see [common kinematic settings](#common-kinematic-settings) for
@ -1644,8 +1637,7 @@ each additional extruder. The additional extruder sections should be
named "extruder1", "extruder2", "extruder3", and so on. See the
"extruder" section for a description of available parameters.
See
[sample-multi-extruder.cfg](https://github.com/KevinOConnor/klipper/tree/master/config/sample-multi-extruder.cfg)
See [sample-multi-extruder.cfg](../config/sample-multi-extruder.cfg)
for an example configuration.
```
@ -1675,9 +1667,8 @@ typically combined with extra extruders - the SET_DUAL_CARRIAGE
command is often called at the same time as the ACTIVATE_EXTRUDER
command. Be sure to park the carriages during deactivation.
See
[sample-idex.cfg](https://github.com/KevinOConnor/klipper/tree/master/config/sample-idex.cfg)
for an example configuration.
See [sample-idex.cfg](../config/sample-idex.cfg) for an example
configuration.
```
[dual_carriage]
@ -1958,9 +1949,9 @@ BME280 two wire interface (I2C) environmental sensor. Note that this
sensor is not intended for use with extruders and heater beds, but
rather for monitoring ambient temperature (C), pressure (hPa), and
relative humidity. See
[sample-macros.cfg](https://github.com/KevinOConnor/klipper/tree/master/config/sample-macros.cfg)
for a gcode_macro that may be used to report pressure and humidity in
addition to temperature.
[sample-macros.cfg](../config/sample-macros.cfg) for a gcode_macro
that may be used to report pressure and humidity in addition to
temperature.
```
#[temperature_sensor my_sensor]
@ -1987,9 +1978,8 @@ addition to temperature.
HTU21D family two wire interface (I2C) environmental sensor. Note that
this sensor is not intended for use with extruders and heater beds,
but rather for monitoring ambient temperature (C) and relative
humidity. See
[sample-macros.cfg](https://github.com/KevinOConnor/klipper/tree/master/config/sample-macros.cfg)
for a gcode_macro that may be used to report humidity in addition to
humidity. See [sample-macros.cfg](../config/sample-macros.cfg) for a
gcode_macro that may be used to report humidity in addition to
temperature.
```
@ -3179,9 +3169,8 @@ will be assigned the given display data which can then be referenced
in the display templates by their name surrounded by two "tilde"
symbols i.e. `~my_display_glyph~`
See
[sample-glyphs.cfg](https://github.com/KevinOConnor/klipper/tree/master/config/sample-glyphs.cfg)
for some examples.
See [sample-glyphs.cfg](../config/sample-glyphs.cfg) for some
examples.
```
[display_glyph my_display_glyph]
@ -3430,8 +3419,7 @@ with an "sx1509" prefix. Each expander provides a set of 16 pins
(sx1509_my_sx1509:PIN_0 to sx1509_my_sx1509:PIN_15) which can be used
in the printer configuration.
See the
[generic-duet2-duex.cfg](https://github.com/KevinOConnor/klipper/tree/master/config/generic-duet2-duex.cfg)
See the [generic-duet2-duex.cfg](../config/generic-duet2-duex.cfg)
file for an example.
```
@ -3483,8 +3471,8 @@ monitoring pins. Be sure to define this config section above any
config sections that use one these virtual pins.
See the
[generic-duet2-maestro.cfg](https://github.com/KevinOConnor/klipper/tree/master/config/generic-duet2-maestro.cfg)
file for an example.
[generic-duet2-maestro.cfg](../config/generic-duet2-maestro.cfg) file
for an example.
```
[adc_scaled my_name]
@ -3503,8 +3491,8 @@ vssa_pin:
## [replicape]
Replicape support - see the [beaglebone guide](beaglebone.md) and the
[generic-replicape.cfg](https://github.com/KevinOConnor/klipper/tree/master/config/generic-replicape.cfg)
file for an example.
[generic-replicape.cfg](../config/generic-replicape.cfg) file for an
example.
```
# The "replicape" config section adds "replicape:stepper_x_enable"

View File

@ -103,12 +103,12 @@ and make sure FLASH_DEVICE is set correctly for your board (see the
However, if "make flash" just doesn't work for your board, then you
will need to manually flash. See if there is a config file in the
[config directory](https://github.com/KevinOConnor/klipper/tree/master/config)
with specific instructions for flashing the device. Also, check the
board manufacturer's documentation to see if it describes how to flash
the device. Finally, it may be possible to manually flash the device
using tools such as "avrdude" or "bossac" - see the
[bootloader document](Bootloaders.md) for additional information.
[config directory](../config) with specific instructions for flashing
the device. Also, check the board manufacturer's documentation to see
if it describes how to flash the device. Finally, it may be possible
to manually flash the device using tools such as "avrdude" or
"bossac" - see the [bootloader document](Bootloaders.md) for
additional information.
### How do I change the serial baud rate?
@ -159,8 +159,7 @@ Klipper has been run on other machines. The Klipper host software only
requires Python running on a Linux (or similar) computer. However, if
you wish to run it on a different machine you will need Linux admin
knowledge to install the system prerequisites for that particular
machine. See the
[install-octopi.sh](https://github.com/KevinOConnor/klipper/tree/master/scripts/install-octopi.sh)
machine. See the [install-octopi.sh](../scripts/install-octopi.sh)
script for further information on the necessary Linux admin steps.
If you are looking to run the Klipper host software on a low-end chip,
@ -199,10 +198,9 @@ own pseudo-tty. For example:
If you choose to do this, you will need to implement the necessary
start, stop, and installation scripts (if any). The
[install-octopi.sh](https://github.com/KevinOConnor/klipper/tree/master/scripts/install-octopi.sh)
script and the
[klipper-start.sh](https://github.com/KevinOConnor/klipper/tree/master/scripts/klipper-start.sh)
script may be useful as examples.
[install-octopi.sh](../scripts/install-octopi.sh) script and the
[klipper-start.sh](../scripts/klipper-start.sh) script may be useful
as examples.
### Do I have to use OctoPrint?
@ -544,9 +542,12 @@ flash" commands are needed for a software change to take effect.
### How do I uninstall Klipper?
On the firmware end, nothing special needs to happen. Just follow the flashing directions for the new firmware.
On the firmware end, nothing special needs to happen. Just follow the
flashing directions for the new firmware.
On the raspberry pi end, an uninstall script is available in [`scripts/klipper-uninstall.sh`](https://github.com/KevinOConnor/klipper/blob/master/scripts/klipper-uninstall.sh). Assuming you cloned `klipper` to `$HOME`
On the raspberry pi end, an uninstall script is available in
[scripts/klipper-uninstall.sh](../scripts/klipper-uninstall.sh). For
example:
```
sudo ~/klipper/scripts/klipper-uninstall.sh
rm -rf ~/klippy-env ~/klipper

View File

@ -140,9 +140,7 @@ Klipper supports many standard 3d printer features:
document for more information.
* Sample configuration files are available for many common printers.
Check the
[config directory](https://github.com/KevinOConnor/klipper/tree/master/config/)
for a list.
Check the [config directory](../config/) for a list.
To get started with Klipper, read the [installation](Installation.md)
guide.

View File

@ -126,7 +126,7 @@ Configuring Klipper
The Klipper configuration is stored in a text file on the Raspberry
Pi. Take a look at the example config files in the
[config directory](https://github.com/KevinOConnor/klipper/tree/master/config/). The
[config directory](../config/). The
[config reference](Config_Reference.md) contains documentation on
config parameters.

View File

@ -54,8 +54,8 @@ Remaining configuration
Complete the installation by configuring Klipper secondary MCU
following the instructions in
[RaspberryPi sample config](https://github.com/KevinOConnor/klipper/tree/master/config/sample-raspberry-pi.cfg) and
[Multi MCU sample config](https://github.com/KevinOConnor/klipper/tree/master/config/sample-multi-mcu.cfg).
[RaspberryPi sample config](../config/sample-raspberry-pi.cfg) and
[Multi MCU sample config](../config/sample-multi-mcu.cfg).
Optional: Identify the correct gpiochip
=======================================

View File

@ -18,9 +18,8 @@ END_PRINT in the slicer's configuration. Defining these actions in the
Klipper configuration may make it easier to tweak the printer's start
and end steps as changes do not require re-slicing.
See
[sample-macros.cfg](https://github.com/KevinOConnor/klipper/tree/master/config/sample-macros.cfg)
for example START_PRINT and END_PRINT macros.
See [sample-macros.cfg](../config/sample-macros.cfg) for example
START_PRINT and END_PRINT macros.
See the [config reference](Config_Reference.md#gcode_macro) for
details on defining a gcode_macro.

View File

@ -118,5 +118,13 @@
$('#toc').append(li);
});
</script>
<!-- Javascript to automatically fix links to files outside docs/ -->
<script>
$("a[href^='../']")
.each(function () {
this.href = $(this).attr("href").replace(/^\.\./, "https://github.com/KevinOConnor/klipper/blob/master");
});
</script>
</body>
</html>