mirror of
https://github.com/Hilbis/Hilbish
synced 2025-04-05 05:03:23 +00:00
* fix: make lua implemented hilbish interfaces documented * fix: signature link in table of contents * fix: reduce function list to match in go generated docs * fix: toc appending * docs: enable docs for hilbish.messages * feat: add description gen, and more spacing between param listing * docs: add more detailed documentation for lua modules * docs: update hilbish.messages docs * fix: add description for lua doc'd modules, remove duplicate docs * docs: add back hilbish.jobs doc * feat: generate toc for lua modules * fix: add table heading * ci: add lua docgen * docs: put dirs.old doc on 1 line
104 lines
1.9 KiB
Markdown
104 lines
1.9 KiB
Markdown
---
|
|
title: Module dirs
|
|
description: internal directory management
|
|
layout: doc
|
|
menu:
|
|
docs:
|
|
parent: "Nature"
|
|
---
|
|
|
|
|
|
## Introduction
|
|
The dirs module defines a small set of functions to store and manage
|
|
directories.
|
|
|
|
## Functions
|
|
|||
|
|
|----|----|
|
|
|<a href="#recent">recent(idx)</a>|Get entry from recent directories list based on index.|
|
|
|<a href="#pop">pop(num)</a>|Remove the specified amount of dirs from the recent directories list.|
|
|
|<a href="#peak">peak(num)</a>|Look at `num` amount of recent directories, starting from the latest.|
|
|
|<a href="#push">push(dir)</a>|Add `dir` to the recent directories list.|
|
|
|<a href="#setOld">setOld(d)</a>|Sets the old directory string.|
|
|
<hr>
|
|
<div id='setOld'>
|
|
<h4 class='heading'>
|
|
dirs.setOld(d)
|
|
<a href="#setOld" class='heading-link'>
|
|
<i class="fas fa-paperclip"></i>
|
|
</a>
|
|
</h4>
|
|
|
|
Sets the old directory string.
|
|
#### Parameters
|
|
`d` **`string`**
|
|
|
|
|
|
</div>
|
|
|
|
<hr>
|
|
<div id='push'>
|
|
<h4 class='heading'>
|
|
dirs.push(dir)
|
|
<a href="#push" class='heading-link'>
|
|
<i class="fas fa-paperclip"></i>
|
|
</a>
|
|
</h4>
|
|
|
|
Add `dir` to the recent directories list.
|
|
#### Parameters
|
|
`dir` **`string`**
|
|
|
|
|
|
</div>
|
|
|
|
<hr>
|
|
<div id='peak'>
|
|
<h4 class='heading'>
|
|
dirs.peak(num)
|
|
<a href="#peak" class='heading-link'>
|
|
<i class="fas fa-paperclip"></i>
|
|
</a>
|
|
</h4>
|
|
|
|
Look at `num` amount of recent directories, starting from the latest.
|
|
This returns a table of recent directories, up to the `num` amount.
|
|
#### Parameters
|
|
`num` **`number`**
|
|
|
|
|
|
</div>
|
|
|
|
<hr>
|
|
<div id='pop'>
|
|
<h4 class='heading'>
|
|
dirs.pop(num)
|
|
<a href="#pop" class='heading-link'>
|
|
<i class="fas fa-paperclip"></i>
|
|
</a>
|
|
</h4>
|
|
|
|
Remove the specified amount of dirs from the recent directories list.
|
|
#### Parameters
|
|
`num` **`number`**
|
|
|
|
|
|
</div>
|
|
|
|
<hr>
|
|
<div id='recent'>
|
|
<h4 class='heading'>
|
|
dirs.recent(idx)
|
|
<a href="#recent" class='heading-link'>
|
|
<i class="fas fa-paperclip"></i>
|
|
</a>
|
|
</h4>
|
|
|
|
Get entry from recent directories list based on index.
|
|
#### Parameters
|
|
`idx` **`number`**
|
|
|
|
|
|
</div>
|
|
|