Organize and access data with Piggydb
Tags and Relations in Piggydb
Although you can assign tags to a knowledge fragment during editing, Piggydb also makes it possible to tag already existing entries easily via drag-and-drop. In the Tag Palette, pick a tag and drag it onto the desired fragments. When you assign a tag to a fragment, Piggydb automatically hyperlinks all occurrences of the tag in all existing fragments. Clicking on the hyperlink shows all fragments containing the specific tag.
Piggydb also supports hierarchical tags, which add a new dimension to the tagging functionality suitable for more granular and effective classification of knowledge fragments. For example, you can create the language tag with the grammar, vocabulary, and notes subtags to keep tabs on language-related fragments. Each subtag in Piggydb can contain a number of its own child tags. For example, the grammar subtag can include the morphology and syntax child tags. The morphology tag can include its own child tags like nouns, verbs, adverbs, and so on. When you assign a specific subtag to a fragment, Piggydb automatically adds parent tags, too. For example, assigning the syntax tag to a fragment automatically adds the grammar and language parent tags. To define hierarchical tags, click on an existing tag to open it in column view (Figure 5). Then use the Tag fields to add parents and children to the selected tag.
A knowledge fragment in Piggydb can act as a tag, too. This feature turns an individual knowledge fragment into a tag fragment that represents a concept. This concept can be used to group other, conceptually similar, fragments. To transform a fragment into a tag fragment, press the As a tag button next to the Title field in the fragment editor. This essentially turns the fragment into a subtag of every tag assigned to the tag fragment. The article The Piggydb Way: #2 Tags as First-Class Components [2] will help you better understand this feature.
Although the tag-fragments can be used to group conceptually similar fragments, the relationship feature lets you establish connections between knowledge fragments. For example, you can create a relation between a fragment explaining how to set up an Apache server and a fragment containing information on how to enable the htaccess feature. To add a relationship, drag the Relationship icon in the floating toolbar of the source fragment and drop it onto the destination fragment (Figure 6). This displays the Create a relationship dialog box, where you can specify the type of relationship (one-way or bi-directional).
Special Tags
In addition to regular tags, Piggydb supports tags reserved for internal use: #bookmark, #pre, #code, #public, and #user. The #bookmark tag can be used to access frequently used knowledge fragments quickly. Knowledge fragments tagged with the #bookmark tag are listed in the Bookmark palette. The easiest way to bookmark a fragment is to use the Bookmark button in the fragment toolbar.
Piggydb provides another way to access specific knowledge fragments: the dedicated button in the fragment toolbar adds the current fragment to the home page. This puts the fragment at the top of the first column in the column view.
The #pre tag renders the content of a fragment without any formatting, while the #code tag adds syntax highlighting. The combination of the two tags can be used for fragments containing code snippets (Figure 7). You can also use the optional #lang-<language name> tag to specify explicitly the programming language of the code in the fragment.
Assigning the #public tag to a fragment makes it accessible for everyone. The public fragment's address has the following format: http://piggydb//document-view.htm?id=<n> (where piggydb is the IP address or domain name of the server running Piggydb and <n> is the ID number of the fragment). To make all public fragments accessible via the http://piggydb/public/ address, assign the #home tag to each of them.
Managing Users in Piggydb
Piggydb provides a rather unique way of managing users. By default, the application has only one user called owner, but you can add other users via special knowledge fragments with the #user tag assigned to them. To add, for example, the guest
user, create a new knowledge fragment, enter guest in the Title field, and assign the #user tag to the fragment. Press Register to save the fragment, and you can then log in to Piggydb using the guest username and password. The user fragments in Piggydb can be treated as regular knowledge fragments – that is, you can assign tags to them, connect to other fragments, and so on.
« Previous 1 2 3 Next »
Buy this article as PDF
(incl. VAT)
Buy Linux Magazine
Subscribe to our Linux Newsletters
Find Linux and Open Source Jobs
Subscribe to our ADMIN Newsletters
Support Our Work
Linux Magazine content is made possible with support from readers like you. Please consider contributing when you’ve found an article to be beneficial.
News
-
Canonical Bumps LTS Support to 12 years
If you're worried that your Ubuntu LTS release won't be supported long enough to last, Canonical has a surprise for you in the form of 12 years of security coverage.
-
Fedora 40 Beta Released Soon
With the official release of Fedora 40 coming in April, it's almost time to download the beta and see what's new.
-
New Pentesting Distribution to Compete with Kali Linux
SnoopGod is now available for your testing needs
-
Juno Computers Launches Another Linux Laptop
If you're looking for a powerhouse laptop that runs Ubuntu, the Juno Computers Neptune 17 v6 should be on your radar.
-
ZorinOS 17.1 Released, Includes Improved Windows App Support
If you need or desire to run Windows applications on Linux, there's one distribution intent on making that easier for you and its new release further improves that feature.
-
Linux Market Share Surpasses 4% for the First Time
Look out Windows and macOS, Linux is on the rise and has even topped ChromeOS to become the fourth most widely used OS around the globe.
-
KDE’s Plasma 6 Officially Available
KDE’s Plasma 6.0 "Megarelease" has happened, and it's brimming with new features, polish, and performance.
-
Latest Version of Tails Unleashed
Tails 6.0 is based on Debian 12 and includes GNOME 43.
-
KDE Announces New Slimbook V with Plenty of Power and KDE’s Plasma 6
If you're a fan of KDE Plasma, you'll be thrilled to hear they've announced a new Slimbook with an AMD CPU and the latest version of KDE Plasma desktop.
-
Monthly Sponsorship Includes Early Access to elementary OS 8
If you want to get a glimpse of what's in the pipeline for elementary OS 8, just set up a monthly sponsorship to help fund its continued existence.