Skip to content

nano - Zeilennummern dauerhaft anzeigen

Linux
3 2 2.8k
  • Ja, das findet man überall im Netz. Aber, da ich gerne wichtige Dinge für mich notiere, hier kurz wie es geht.

    Der Texteditor nano zeigt in der Grundeinstellung keine Zeilennummern an. Blöd, wenn man mal eben in irgendeinem Quellcode kurz was ändern muss und man nach Zeile 385 suchen muss.

    Das kann man ändern 😉

    Temporär

    Mit der Tastenkombi ALT + c wird die Zeilennummer unten eingeblendet.

    157bee86-75dc-4cb4-89ed-b03d05e31d6d-grafik.png

    Dauerhaft

    In der Datei ~/.nanorc folgende Zeile eintragen.

    set linenumbers
    

    6c9bcfa3-6381-47c5-b3e5-6c5f9063a632-grafik.png

  • In dem Ubuntu 24.04. WSL Distro funktioniert es nicht

    cat << EOF > ~/.nanorc
    set linenumbers
    EOF
    source ~/.nanorc

    Was bei mir funktioniert ist:

    cat << EOF >> ~/.bashrc
    alias nano='sudo nano -l'
    EOF
    source ~/.bashrc

    mfg

  • @masko Danke für die Ergänzung.

    Um den Code zu markieren, kannst Du im Texteditor auf </> klicken oder einfach 4 Leerzeichen vor den Code setzen. Dann sieht es besser aus 😉

    Und Willkommen im Forum!

  • ...

    Uncategorized linux softwareentwick desktop jahrdeslinuxdes endof10
    1
    0 Stimmen
    1 Beiträge
    2 Aufrufe
    Niemand hat geantwortet
  • 450 Stimmen
    27 Beiträge
    123 Aufrufe
    A
    This is the kind of news I want to keep seein’!
  • OpenCloud - Desktop Client

    OpenCloud opencloud linux
    1
    5
    0 Stimmen
    1 Beiträge
    103 Aufrufe
    Niemand hat geantwortet
  • OpenCloud - Docker Compose local

    Verschoben OpenCloud opencloud linux
    3
    1
    0 Stimmen
    3 Beiträge
    579 Aufrufe
    FrankMF
    Noch was Wichtiges. Die Docker Installation nutzt folgende config. In meinem Beispiel findet man sie unter /home/frank/opencloud/deployments/examples/opencloud_full Darin liegt ein .env ## Basic Settings ## # Define the docker compose log driver used. # Defaults to local LOG_DRIVER= # If you're on an internet facing server, comment out following line. # It skips certificate validation for various parts of OpenCloud and is # needed when self signed certificates are used. INSECURE=true ## Traefik Settings ## # Note: Traefik is always enabled and can't be disabled. # Serve Traefik dashboard. # Defaults to "false". TRAEFIK_DASHBOARD= # Domain of Traefik, where you can find the dashboard. # Defaults to "traefik.opencloud.test" TRAEFIK_DOMAIN= # Basic authentication for the traefik dashboard. # Defaults to user "admin" and password "admin" (written as: "admin:$2y$05$KDHu3xq92SPaO3G8Ybkc7edd51pPLJcG1nWk3lmlrIdANQ/B6r5pq"). # To create user:password pair, it's possible to use this command: # echo $(htpasswd -nB user) | sed -e s/\\$/\\$\\$/g TRAEFIK_BASIC_AUTH_USERS= # Email address for obtaining LetsEncrypt certificates. # Needs only be changed if this is a public facing server. TRAEFIK_ACME_MAIL= # Set to the following for testing to check the certificate process: # "https://acme-staging-v02.api.letsencrypt.org/directory" # With staging configured, there will be an SSL error in the browser. # When certificates are displayed and are emitted by # "Fake LE Intermediate X1", # the process went well and the envvar can be reset to empty to get valid certificates. TRAEFIK_ACME_CASERVER= [....gekürzt....] Man kann dort etwas ändern und mittels docker compose up -d alles aktualisieren. Radicale OpenCloud nutzt im Moment folgendes https://radicale.org/v3.html als Backend Server für Kalender & Kontakte. Jemand hat mir dann erklärt, wie das so funktioniert. Danach hatte es dann klick gemacht. https://fosstodon.org/@h4kamp/114562514701351170 In der config findet man zum Beispiel die Konfiguration für radicale (Kalender- und Kontakte-App) Das ist nur eine rudimentäre Ablage, wird gesteuert über Clienten, z.B. die Thunderbird Kalender Funktion. ### Radicale Setting ### # Radicale is a small open-source CalDAV (calendars, to-do lists) and CardDAV (contacts) server. # When enabled OpenCloud is configured as a reverse proxy for Radicale, providing all authenticated # OpenCloud users access to a Personal Calendar and Addressbook RADICALE=:radicale.yml # Docker image to use for the Radicale Container #RADICALE_DOCKER_IMAGE=opencloudeu/radicale # Docker tag to pull for the Radicale Container #RADICALE_DOCKER_TAG=latest # Define the storage location for the Radicale data. Set the path to a local path. # Ensure that the configuration and data directories are owned by the user and group with ID 1000:1000. # This matches the default user inside the container and avoids permission issues when accessing files. # Leaving it default stores data in docker internal volumes. #RADICALE_DATA_DIR=/your/local/radicale/data In einer Standard Installation ist das auskommentiert. RADICALE=:radicale.yml Danach ein docker compose up -d und Eure Kalendereinträge (extern auf einem Clienten verwaltet) werden in der OpenCloud gesichert.
  • Update 1.30.3 released

    Vaultwarden vaultwarden linux
    1
    0 Stimmen
    1 Beiträge
    152 Aufrufe
    Niemand hat geantwortet
  • Firefox - Cookie Banner blocken

    Linux firefox linux
    1
    0 Stimmen
    1 Beiträge
    218 Aufrufe
    Niemand hat geantwortet
  • Minicom

    Linux linux
    1
    1
    0 Stimmen
    1 Beiträge
    536 Aufrufe
    Niemand hat geantwortet
  • Projekt NAS - BIOS Update 1.25.0

    Linux linux
    1
    0 Stimmen
    1 Beiträge
    683 Aufrufe
    Niemand hat geantwortet