How to post code as code in OpenMandriva forum posts

User Information: To post code as code in the window where one writes their reply or post use the </> icon. Highlight the part that is code and click on that icon. Any output in a terminal or Konsole is considered code. Contents of system files and any configuration files are code.

This shows the code or preformatted text icon:

Why this is important? It makes the code a lot easier for someone to read and understand as code. It helps people trying to help users with issues differentiate between what is description and what is code. We are a small, all volunteer, part time group. Time is precious, we all have more on our “To Do” lists than we can get done.

Thanks for your consideration on this.

1 Like

This is example of code posted as code:

$ cpupower frequency-info
analyzing CPU 0:
  driver: acpi-cpufreq
  CPUs which run at the same hardware frequency: 0
  CPUs which need to have their frequency coordinated by software: 0
  maximum transition latency:  Cannot determine or is not supported.
  hardware limits: 2.20 GHz - 3.60 GHz
  available frequency steps:  3.60 GHz, 2.80 GHz, 2.20 GHz
  available cpufreq governors: conservative ondemand userspace powersave performance schedutil
  current policy: frequency should be within 2.20 GHz and 3.60 GHz.
                  The governor "ondemand" may decide which speed to use
                  within this range.
  current CPU frequency: Unable to call hardware
  current CPU frequency: 2.24 GHz (asserted by call to kernel)
  boost state support:
    Supported: yes
    Active: no
1 Like

You can also post code as code using the tick mark (not apostrophe) ` before and after the text you wish to post as code. Say I want to post this as code:

$ cat /etc/release
OpenMandriva Lx release 4.50 (Nickel) Cooker for znver1

adding the ` mark at the very beginning and very end results:

$ cat /etc/release OpenMandriva Lx release 4.50 (Nickel) Cooker for znver1