ArticleslgStudy

computer science

Application directory

Application directory is a computer science topic covered in the lgStudy science library. This page brings together a partial reference excerpt, illustrations, worked examples, real-world applications and a short study plan, so you can understand Application directory rather than just read about it. In short: An application directory is a grouping of software code, help files and resources that together comprise a complete software package but are presented to the user as a single object. They are currently used in RISC OS and the ROX Desktop, and also form the basis of the Zero Install application distribution system.

Application directory — main illustration
Application directory — illustration

Key takeaways

  • Application directory belongs to computer science; place it in that map before memorising details.
  • Learn the definition first, then one example that makes the definition concrete.
  • Connect Application directory to a quantity you can measure, compute or draw — that is where exam questions come from.
  • Reproduce the core statement of Application directory from memory before moving on to harder problems.

Reference excerpt

An application directory is a grouping of software code, help files and resources that together comprise a complete software package but are presented to the user as a single object. They are currently used in RISC OS and the ROX Desktop, and also form the basis of the Zero Install application distribution system. Similar technology includes VMware ThinApp, and the NEXTSTEP/GNUstep/Mac OS X concept of application bundles. Their heritage lies in the system for automatically launching software stored on floppy disk on Acorn's earlier 8-bit micros such as the BBC Micro (the !BOOT file). Bundling various files in this manner allows tools for manipulating applications to be replaced by tools for manipulating the file system. Applications can often be "installed" simply by dragging them from a distribution medium to a hard disk, and "uninstalled" by deleting the application directory.

Fixed contents

In order to support user interaction with application directories, several files have special status.

Application binaries Launching an application directory causes the included file AppRun (ROX Desktop) or !Run (RISC OS) to be launched. On RISC OS this is generally an Obey file (a RISC OS command script) which allocates memory and loads OS extension modules and shared libraries before executing the application binary, usually called !RunImage. Under the ROX Desktop, it is not uncommon for it to be a shell script that will launch the correct system binary if available or compile a suitable binary from source otherwise.

Help files and icons Both RISC OS and the ROX Desktop allow the user to view help files associated with an application directory without launching the application. RISC OS relies on a file in the directory named !Help which is launched as if the user double-clicked on it when help is requested (and can be any format the system understands, but plain text and !Draw formats are common), while the ROX Desktop opens the application's Help subdirectory. Similarly, custom icons for the Application Directory may be contained within it—either .DirIcon (in any supported image format) or AppIcon.xpm under the ROX Desktop, or !Sprites and optionally !Sprites22 under RISC OS. The RISC OS Filer automatically loads these sprite files in the absence of a !Boot file, otherwise it is left to the !Boot file to load the appropriate icons.

!Boot

RISC OS application directories may contain a file named !Boot which is executed by the Filer either explicitly via the FilerBoot command, or when the bundle is first displayed (unless the user held Control when opening that Filer window, which defeats application booting). This allows an application to do tasks such as register supported filetypes (by defining their name, setting command aliases for running or printing them and loading appropriate icons), or choose to load different icons such as ASprites (icons with an alpha channel for RISC OS Select), 5Sprites (icons with a RISC OS 5 appearance) or theme-specific icons. !Boot files are the most popular propagation vector for such RISC OS viruses as exist (such as the well-known Extend virus), though they can be defeated simply by holding Control. The !Boot feature is not duplicated by the ROX Desktop.

The RISC OS !Boot system directory Acorn's early machines allowed a medium to be "booted" (automatically run) by executing a file called !BOOT if present (this action, "booting a disc", was toggled with the Shift, and hence became known as shift-booting). This was exploited in the RISC OS disc structure by having an application directory in the root of the default disc called !Boot. This application directory is executed (run) when the machine boots (if so configured), therefore causing its !Run file to be executed (i.e. $.!Boot.!Run in Acorn pathname syntax). This file then causes various files to be executed, OS modules loaded, standard icons to be loaded and filetypes defined, and defines a number of standard variables through which its various subdirectories are accessed. Thus RISC OS's entire boot sequence can be avoided merely by holding Shift.

See also Bundle (OS X) Application Virtualization Portable application creators

Notes

External links ROX-Filer User Manual: Application directories

Illustrations

Application directory: RISC OS: Contents of the !Draw application directory
RISC OS: Contents of the !Draw application directory
Application directory: RISC OS: Contents of !Draw's !Sprites22 file
RISC OS: Contents of !Draw's !Sprites22 file
Application directory: RISC OS: !Draw's !Boot, !Run and !Help files
RISC OS: !Draw's !Boot, !Run and !Help files

Worked examples

Example 1 — a first encounter with Application directory

Start with the simplest possible case. Write down what Application directory claims or describes in one sentence, then invent the smallest concrete situation in which that sentence is true. In computer science, the smallest case is usually a single object, a single equation or a single measurement. Check that every symbol or term in your sentence has a meaning in that case.

Example 2 — changing one variable

Take the situation from Example 1 and change exactly one quantity: double it, halve it, or set it to zero. Predict what should happen to Application directory before you calculate. Comparing your prediction with the result is the fastest way to find out whether you understand the idea or only the words.

Example 3 — an exam-style question

Typical questions about Application directory ask you to (a) state it precisely, (b) apply it to given data, and (c) explain a limitation. Practise writing all three answers in under five minutes; the third part is what separates a full-mark answer from an average one.

Applications of Application directory

In research
Application directory appears in computer science research whenever the underlying quantities have to be modelled precisely. Papers usually cite it as a starting assumption and then explore where it breaks down.
In technology and industry
Engineering practice reuses Application directory in design rules, simulations and safety margins. Knowing the idea lets you read a specification sheet and understand why the numbers look the way they do.
In the classroom
Application directory is common in secondary-school and first-year university syllabi. It links to neighbouring topics Software distribution, Source code, so understanding it makes those chapters shorter.
In everyday life
Look for Application directory outside the textbook — in sport, cooking, traffic, electronics or the sky above you. An example you found yourself is remembered far longer than one you were given.
Ask Teacher Smith questions about this articleOpens your AI tutor with a question about “Application directory” →

How to study Application directory in 20 minutes

  1. Read the reference excerpt below once, without taking notes.
  2. Close the page and write down what Application directory means in your own words.
  3. Compare your version with the excerpt and mark what you missed.
  4. Work through the three examples above with pen and paper.
  5. Explain Application directory out loud to somebody else — or to Teacher Smith in the lgStudy chat.

Frequently asked questions

What is Application directory in simple terms?

An application directory is a grouping of software code, help files and resources that together comprise a complete software package but are presented to the user as a single object. They are currently used in RISC OS and the ROX Desktop, and also form the basis of the Zero Install application dist…

Why does Application directory matter?

Because it connects several computer science ideas at once: it gives you a definition you can apply, a quantity you can calculate, and a way to check whether a result is plausible.

How should I study Application directory?

Read the excerpt, restate it from memory, then work through the examples and applications listed on this page. The five-step study plan above takes about twenty minutes.

What does this page cover?

It gives you a compact reference excerpt plus original lgStudy explanations, examples, applications and study material on Application directory.

Tags

  • Software distribution
  • Source code

Keep exploring