Zum Inhalt springen
View in the app

A better way to browse. Learn more.

Fachinformatiker.de

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Wie kann ich die Kommentare von den Konfiguration Dateien löschen

Empfohlene Antworten

Veröffentlicht

ich möchte die Kommentare von den Konfiguration Dateien löschen und dann die reine Konfiguration Information in eine Datei schreiben um nur die Konfiguration Information zu sehen.

z.B.

Squid Config

# TAG: http_port

# Usage: port

# hostname:port

# 1.2.3.4:port

#

# The socket addresses where Squid will listen for HTTP client

# requests. You may specify multiple socket addresses.

# There are three forms: port alone, hostname with port, and

# IP address with port. If you specify a hostname or IP

# address, then Squid binds the socket to that specific

# address. This replaces the old 'tcp_incoming_address'

# option. Most likely, you do not need to bind to a specific

# address, so you can use the port number alone.

#

# The default port number is 3128.

#

# If you are running Squid in accelerator mode, then you

# probably want to listen on port 80 also, or instead.

#

# The -a command line option will override the *first* port

# number listed here. That option will NOT override an IP

# address, however.

#

# You may specify multiple socket addresses on multiple lines.

#

# If you run Squid on a dual-homed machine with an internal

# and an external interface then we recommend you to specify the

# internal address:port in http_port. This way Squid will only be

# visible on the internal address.

#

#Default:

http_port 3128

Quick und Dirty:

cat Konfigurationsdatei | grep -v "#" >> Konfigurationsdatei_neu

sehr dirty .... da es ja auch solche einträge geben könnte:

http_blabla = 25 # number of http blablas allowed per minute

also wenn dem eintrag noch ein comment folgt, was durchaus auch üblich ist... aber das wäre mir auf anhieb auch eingefallen, musst halt mal schaun ob es dir was bringt.

wenn ich später mal zeit habe schau ich mal ob mir was anderes einfällt *g*

Dann halt sauber:

cat Konfigurationsdatei | sed "^[^#]*?" >> Konfigurationsdatei_neu

Hallo,

Quick und Dirty:

cat Konfigurationsdatei | grep -v "#" >> Konfigurationsdatei_neu

bei mir funktioniert das nicht:

sed: -e expression #1, char 1: Unknown command: `^'

Mindestens genauso sauber:


cat Konfigurationsdatei | grep -Ev "^#" >> Konfigurationsdatei_neu

:D

grep -E .... Danke Schlaubi. *sed wegschmeiß* :)

Archiv

Dieses Thema wurde archiviert und kann nicht mehr beantwortet werden.

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.