Skip to content
View in the app

A better way to browse. Learn more.

Unraid

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.

[unMENU] How put comments in package conf files?

Featured Replies

Joe,

 

I would like to put some comments in the conf files. Whenever is use # unMENU hangs. Is there some sort of comment possible?

 

Thanks in advance

Harald

 

 

Joe,

 

I would like to put some comments in the conf files. Whenever is use # unMENU hangs. Is there some sort of comment possible?

 

Thanks in advance

Harald

 

 

I have put comments in the files in the past.  As far as I can remember from when I wrote the code reading in the package files, unless the line in the file has one of the "PACKAGE_xxxxxx" tags it knows, it will be ignored.

 

Can you post an example of a file you were trying to create that hangs?

 

Joe L.

  • Author

Hi Joe,

 

sure. Do you see these two  comments '#'? I just tried it to be sure and the awk process died. If it doesn't die the Package Manager screen won't show up at least. If you remove the '#' all will be fine:

 

PACKAGE_NAME libxml2 (XML parser library)
PACKAGE_DESCR Libxml2 is the XML C parser library and toolkit.  XML itself is a
PACKAGE_DESCR metalanguage to design markup languages  -- i.e. a text language where
PACKAGE_DESCR structures are added to the content using extra "markup" information
PACKAGE_DESCR enclosed between angle brackets.  HTML is the most well-known markup
PACKAGE_DESCR language.  Though the library is written in C, a variety of language
PACKAGE_DESCR bindings make it available in other environments.
PACKAGE_URL http://slackware.cs.utah.edu/pub/slackware/slackware-current/slackware/l/libxml2-2.6.32-i486-2.tgz
PACKAGE_FILE libxml2-2.6.32-i486-2.tgz
PACKAGE_MD5 437e25e2abb0a557883cf376281b5944
PACKAGE_INSTALLED /usr/lib/libxml2.so
PACKAGE_DEPENDENCIES none
PACKAGE_INSTALLATION installpkg libxml2-2.6.32-i486-2.tgz
#PACKAGE_VERSION_TEST ls -l libxml2.so 2>&1 | grep 'libxml2.so' | awk '{print $4}'
#PACKAGE_VERSION_STRING libxml2.so:
PACKAGE_MEMORY_USAGE n/a

 

Thanks

Harald

 

 

The lines you commented out are required by the package manager... they must be in each and every package .conf file in order for the plug-in to work.  I ran into this problem in my previous testing.  I had to go through the package manager code to figure it out.

 

 

Cheers,

Matt

  • Author

Thanks, did you find a way how to comment lines - if there is any?

 

Regards

Harald

 

 

What you asked "How do I put comments in a package.conf file" is not the same as what you are trying to do.  You are trying to not perform the package version test.

 

The PACKAGE_VERSION_TEST tag is required, but you can just use "echo" as the test, and then use a blank PACKAGE_VERSION_STRING

 

Like this:

PACKAGE_VERSION_TEST echo

PACKAGE_VERSION_STRING

 

Another way to handle a library or file that does not have a specific "version' string would be to use a checksum of the installed file

Something like:

PACKAGE_VERSION_TEST md5sum /the/path/to/your/file

PACKAGE_VERSION_STRING the_md5_checksum

 

That way, you can tell if a specific version of a file exists. 

 

To me, putting comments in the file is as easy as putting ANY text in the package-conf file that does not start a line with one of the pre-defined "tags"  Those lines are all ignored.  (Any line that puts a "#" in front of a valid "tag" are also ignored.  The config "tag" keywords must all start at the beginning of a line, even a leading space would make them get ignored.)  In any case, that is why I could add comments and you could not, and why I asked for an example.  We were thinking of two different things.

 

Joe L.

  • Author

Ah, I see. My problem was not the #. It was the missing tag.

 

When I wrote my first conf I 'commented' (at least I thought so) all lines that were not finished yet. After a crash I stopped using the #.

 

Some days later I was thinking about using comments in conf files and thought that I can't use comments because of the crash.

 

I was counting 1+1 and got 3 ;-)

 

Thanks for your help.

Harald

 

 

Archived

This topic is now archived and is closed to further replies.

Account

Navigation

Search

Search

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.