Skip to content

Re-structure common docs files into sub-folders. #2268

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Oct 3, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion website/docs/Command-Line-Arguments.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ An _action_ indicates what Premake should do on any given run. For instance, the

An _option_ modifies the behavior of the action. For instance, the `dotnet` option is used to change which .NET compiler set is used in the generated files. Options can accept a value, such as `--dotnet=mono` or act as a flag, like `--with-opengl`.

From within your script, you can identify the current action with the [`_ACTION`](premake_ACTION.md) global variable, a string value. You can check for an option using the [`_OPTIONS`](premake_OPTIONS.md) table, which contains a list of key-value pairs. The key is the option identifier ("dotnet"), which references the command line value ("mono") or an empty string for valueless options.
From within your script, you can identify the current action with the [`_ACTION`](globals/premake_ACTION.md) global variable, a string value. You can check for an option using the [`_OPTIONS`](globals/premake_OPTIONS.md) table, which contains a list of key-value pairs. The key is the option identifier ("dotnet"), which references the command line value ("mono") or an empty string for valueless options.

```lua
-- delete a file if the clean action is running
Expand Down
2 changes: 1 addition & 1 deletion website/docs/Linking.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ You can tell Premake where to search for libraries with the [`libdirs`](libdirs.
libdirs { "libs", "../mylibs" }
```

If you need to discover the location of a library, use the [`os.findlib`](os.findlib.md) function.
If you need to discover the location of a library, use the [`os.findlib`](os/os.findlib.md) function.

```lua
libdirs { os.findlib("X11") }
Expand Down
204 changes: 102 additions & 102 deletions website/docs/Lua-Library-Additions.md
Original file line number Diff line number Diff line change
@@ -1,19 +1,19 @@
### Globals

* [dofileopt](dofileopt.md)
* [include](include.md)
* [includeexternal](includeexternal.md)
* [require](require.md)
* [dofileopt](globals/dofileopt.md)
* [include](globals/include.md)
* [includeexternal](globals/includeexternal.md)
* [require](globals/require.md)

### Debugging

* [debug.prompt](debug.prompt.md)

### HTTP/S

* [http.download](http.download.md)
* [http.get](http.get.md)
* [http.post](http.post.md)
* [http.download](http/http.download.md)
* [http.get](http/http.get.md)
* [http.post](http/http.post.md)

### I/O

Expand All @@ -22,117 +22,117 @@

### JSON

* [json.decode](json.decode.md)
* [json.encode](json.encode.md)
* [json.decode](json/json.decode.md)
* [json.encode](json/json.encode.md)

### OS

* [os.chdir](os.chdir.md)
* [os.chmod](os.chmod.md)
* [os.comparefiles](os.comparefiles.md)
* [os.copyfile](os.copyfile.md)
* [os.executef](os.executef.md)
* [os.findheader](os.findheader.md)
* [os.findlib](os.findlib.md)
* [os.get](os.get.md)
* [os.getcwd](os.getcwd.md)
* [os.getpass](os.getpass.md)
* [os.getversion](os.getversion.md)
* [os.host](os.host.md)
* [os.hostarch](os.hostarch.md)
* [os.is](os.is.md)
* [os.is64bit](os.is64bit.md)
* [os.isdir](os.isdir.md)
* [os.isfile](os.isfile.md)
* [os.islink](os.islink.md)
* [os.locate](os.locate.md)
* [os.matchdirs](os.matchdirs.md)
* [os.matchfiles](os.matchfiles.md)
* [os.mkdir](os.mkdir.md)
* [os.outputof](os.outputof.md)
* [os.pathsearch](os.pathsearch.md)
* [os.realpath](os.realpath.md)
* [os.remove](os.remove.md)
* [os.rmdir](os.rmdir.md)
* [os.stat](os.stat.md)
* [os.target](os.target.md)
* [os.touchfile](os.touchfile.md)
* [os.translateCommands](os.translateCommands.md)
* [os.uuid](os.uuid.md)
* [os.writefile_ifnotequal](os.writefile_ifnotequal.md)
* [os.chdir](os/os.chdir.md)
* [os.chmod](os/os.chmod.md)
* [os.comparefiles](os/os.comparefiles.md)
* [os.copyfile](os/os.copyfile.md)
* [os.executef](os/os.executef.md)
* [os.findheader](os/os.findheader.md)
* [os.findlib](os/os.findlib.md)
* [os.get](os/os.get.md)
* [os.getcwd](os/os.getcwd.md)
* [os.getpass](os/os.getpass.md)
* [os.getversion](os/os.getversion.md)
* [os.host](os/os.host.md)
* [os.hostarch](os/os.hostarch.md)
* [os.is](os/os.is.md)
* [os.is64bit](os/os.is64bit.md)
* [os.isdir](os/os.isdir.md)
* [os.isfile](os/os.isfile.md)
* [os.islink](os/os.islink.md)
* [os.locate](os/os.locate.md)
* [os.matchdirs](os/os.matchdirs.md)
* [os.matchfiles](os/os.matchfiles.md)
* [os.mkdir](os/os.mkdir.md)
* [os.outputof](os/os.outputof.md)
* [os.pathsearch](os/os.pathsearch.md)
* [os.realpath](os/os.realpath.md)
* [os.remove](os/os.remove.md)
* [os.rmdir](os/os.rmdir.md)
* [os.stat](os/os.stat.md)
* [os.target](os/os.target.md)
* [os.touchfile](os/os.touchfile.md)
* [os.translateCommands](os/os.translateCommands.md)
* [os.uuid](os/os.uuid.md)
* [os.writefile_ifnotequal](os/os.writefile_ifnotequal.md)

### Path

* [path.appendExtension](path.appendExtension.md)
* [path.getabsolute](path.getabsolute.md)
* [path.getbasename](path.getbasename.md)
* [path.getdirectory](path.getdirectory.md)
* [path.getdrive](path.getdrive.md)
* [path.getextension](path.getextension.md)
* [path.getname](path.getname.md)
* [path.getrelative](path.getrelative.md)
* [path.hasextension](path.hasextension.md)
* [path.isabsolute](path.isabsolute.md)
* [path.iscfile](path.iscfile.md)
* [path.iscppfile](path.iscppfile.md)
* [path.iscppheader](path.iscppheader.md)
* [path.isframework](path.isframework.md)
* [path.islinkable](path.islinkable.md)
* [path.isobjectfile](path.isobjectfile.md)
* [path.isresourcefile](path.isresourcefile.md)
* [path.join](path.join.md)
* [path.normalize](path.normalize.md)
* [path.rebase](path.rebase.md)
* [path.replaceextension](path.replaceextension.md)
* [path.translate](path.translate.md)
* [path.wildcards](path.wildcards.md)
* [path.appendExtension](path/path.appendExtension.md)
* [path.getabsolute](path/path.getabsolute.md)
* [path.getbasename](path/path.getbasename.md)
* [path.getdirectory](path/path.getdirectory.md)
* [path.getdrive](path/path.getdrive.md)
* [path.getextension](path/path.getextension.md)
* [path.getname](path/path.getname.md)
* [path.getrelative](path/path.getrelative.md)
* [path.hasextension](path/path.hasextension.md)
* [path.isabsolute](path/path.isabsolute.md)
* [path.iscfile](path/path.iscfile.md)
* [path.iscppfile](path/path.iscppfile.md)
* [path.iscppheader](path/path.iscppheader.md)
* [path.isframework](path/path.isframework.md)
* [path.islinkable](path/path.islinkable.md)
* [path.isobjectfile](path/path.isobjectfile.md)
* [path.isresourcefile](path/path.isresourcefile.md)
* [path.join](path/path.join.md)
* [path.normalize](path/path.normalize.md)
* [path.rebase](path/path.rebase.md)
* [path.replaceextension](path/path.replaceextension.md)
* [path.translate](path/path.translate.md)
* [path.wildcards](path/path.wildcards.md)

### String

* [string.capitalized](string.capitalized.md)
* [string.contains](string.contains.md)
* [string.endswith](string.endswith.md)
* [string.escapepattern](string.escapepattern.md)
* [string.explode](string.explode.md)
* [string.findlast](string.findlast.md)
* [string.hash](string.hash.md)
* [string.lines](string.lines.md)
* [string.plural](string.plural.md)
* [string.sha1](string.sha1.md)
* [string.startswith](string.startswith.md)
* [string.capitalized](string/string.capitalized.md)
* [string.contains](string/string.contains.md)
* [string.endswith](string/string.endswith.md)
* [string.escapepattern](string/string.escapepattern.md)
* [string.explode](string/string.explode.md)
* [string.findlast](string/string.findlast.md)
* [string.hash](string/string.hash.md)
* [string.lines](string/string.lines.md)
* [string.plural](string/string.plural.md)
* [string.sha1](string/string.sha1.md)
* [string.startswith](string/string.startswith.md)

### Table

* [table.arraycopy](table.arraycopy.md)
* [table.contains](table.contains.md)
* [table.deepcopy](table.deepcopy.md)
* [table.extract](table.extract.md)
* [table.filterempty](table.filterempty.md)
* [table.flatten](table.flatten.md)
* [table.fold](table.fold.md)
* [table.foreachi](table.foreachi.md)
* [table.implode](table.implode.md)
* [table.indexof](table.indexof.md)
* [table.insertafter](table.insertafter.md)
* [table.insertflat](table.insertflat.md)
* [table.isempty](table.isempty.md)
* [table.join](table.join.md)
* [table.keys](table.keys.md)
* [table.merge](table.merge.md)
* [table.replace](table.replace.md)
* [table.tostring](table.tostring.md)
* [table.translate](table.translate.md)
* [table.arraycopy](table/table.arraycopy.md)
* [table.contains](table/table.contains.md)
* [table.deepcopy](table/table.deepcopy.md)
* [table.extract](table/table.extract.md)
* [table.filterempty](table/table.filterempty.md)
* [table.flatten](table/table.flatten.md)
* [table.fold](table/table.fold.md)
* [table.foreachi](table/table.foreachi.md)
* [table.implode](table/table.implode.md)
* [table.indexof](table/table.indexof.md)
* [table.insertafter](table/table.insertafter.md)
* [table.insertflat](table/table.insertflat.md)
* [table.isempty](table/table.isempty.md)
* [table.join](table/table.join.md)
* [table.keys](table/table.keys.md)
* [table.merge](table/table.merge.md)
* [table.replace](table/table.replace.md)
* [table.tostring](table/table.tostring.md)
* [table.translate](table/table.translate.md)

### Term

* [term.getTextColor](term.getTextColor.md)
* [term.setTextColor](term.setTextColor.md)
* [term.pushColor](term.pushColor.md)
* [term.popColor](term.popColor.md)
* [term.clearToEndOfLine](term.clearToEndOfLine.md)
* [term.moveLeft](term.moveLeft.md)
* [term.getTextColor](term/term.getTextColor.md)
* [term.setTextColor](term/term.setTextColor.md)
* [term.pushColor](term/term.pushColor.md)
* [term.popColor](term/term.popColor.md)
* [term.clearToEndOfLine](term/term.clearToEndOfLine.md)
* [term.moveLeft](term/term.moveLeft.md)

### Zip

* [zip.extract](zip.extract.md)
* [zip.extract](zip/zip.extract.md)

2 changes: 1 addition & 1 deletion website/docs/Overrides-and-Call-Arrays.md
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ end)

This snippet replaces the original implementation of `m.project()` with my new (anonymous) function. From this point on, when someone calls `m.project()`, Premake will call my new function, passing it the original implementation as the first argument (`base`). If the function requires any other arguments (in this case, it receives the project being exported as `prj`) they appear after.

In our replacement function, we emit our comment header using `premake.w()`, which is short for "premake write", and [_PREMAKE_VERSION](premake_PREMAKE_VERSION.md), which is a global variable holding the version of the currently running Premake executable.
In our replacement function, we emit our comment header using `premake.w()`, which is short for "premake write", and [_PREMAKE_VERSION](globals/premake_PREMAKE_VERSION.md), which is a global variable holding the version of the currently running Premake executable.

After emitting the comment we call `base(prj)`, the original implementation of `m.project()`, to do the rest of the work for us. Easy!

Expand Down
24 changes: 12 additions & 12 deletions website/docs/Project-API.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,16 +2,16 @@

| API | Brief |
|-----------------------------------------------------------|--------------------|
| [_ACTION](premake_ACTION.md) | The action that will be run |
| [_ARGS](premake_ARGS.md) | Array of action args |
| [_MAIN_SCRIPT](premake_MAIN_SCRIPT.md) | |
| [_MAIN_SCRIPT_DIR](premake_MAIN_SCRIPT_DIR.md) | |
| [_OPTIONS](premake_OPTIONS.md) | |
| [_OS](premake_OS.md) | The currently targeted operating system |
| [_PREMAKE_COMMAND](premake_PREMAKE_COMMAND.md) | |
| [_PREMAKE_DIR](premake_PREMAKE_DIR.md) | |
| [_PREMAKE_VERSION](premake_PREMAKE_VERSION.md) | The version of the currently executing instance of Premake |
| [_WORKING_DIR](premake_WORKING_DIR.md) | |
| [_ACTION](globals/premake_ACTION.md) | The action that will be run |
| [_ARGS](globals/premake_ARGS.md) | Array of action args |
| [_MAIN_SCRIPT](globals/premake_MAIN_SCRIPT.md) | |
| [_MAIN_SCRIPT_DIR](globals/premake_MAIN_SCRIPT_DIR.md) | |
| [_OPTIONS](globals/premake_OPTIONS.md) | |
| [_OS](globals/premake_OS.md) | The currently targeted operating system |
| [_PREMAKE_COMMAND](globals/premake_PREMAKE_COMMAND.md) | |
| [_PREMAKE_DIR](globals/premake_PREMAKE_DIR.md) | |
| [_PREMAKE_VERSION](globals/premake_PREMAKE_VERSION.md) | The version of the currently executing instance of Premake |
| [_WORKING_DIR](globals/premake_WORKING_DIR.md) | |
| [architecture](architecture.md) | |
| [atl](atl.md) | Use Microsoft's Active Template Library |
| [basedir](basedir.md) | |
Expand Down Expand Up @@ -107,10 +107,10 @@
| [implibname](implibname.md) | |
| [implibprefix](implibprefix.md) | |
| [implibsuffix](implibsuffix.md) | |
| [include](include.md) | |
| [include](globals/include.md) | |
| [includedirs](includedirs.md) | |
| [includedirsafter](includedirsafter.md) | |
| [includeexternal](includeexternal.md) | |
| [includeexternal](globals/includeexternal.md) | |
| [inlining](inlining.md) | Tells the compiler when it should inline functions |
| [intrinsics](intrinsics.md) | |
| [kind](kind.md) | |
Expand Down
4 changes: 2 additions & 2 deletions website/docs/Tokens.md
Original file line number Diff line number Diff line change
Expand Up @@ -87,8 +87,8 @@ You can use command tokens anywhere you specify a command line, including:

* [buildcommands](buildcommands.md)
* [cleancommands](cleancommands.md)
* [os.execute](os.execute.md)
* [os.executef](os.executef.md)
* [os.execute](os/os.execute.md)
* [os.executef](os/os.executef.md)
* [postbuildcommands](postbuildcommands.md)
* [prebuildcommands](prebuildcommands.md)
* [prelinkcommands](prelinkcommands.md)
Expand Down
4 changes: 2 additions & 2 deletions website/docs/Using-Modules.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,10 +37,10 @@ If you wish to make a module always available to *all* of your projects, you may

## Version Requirements

To ensure compatibility with your project script, it can sometimes be helpful to require a minimum version or range of versions for your module dependencies. Premake includes [a modified version Lua's `require()` function](require.md) which accepts a version test as its second argument.
To ensure compatibility with your project script, it can sometimes be helpful to require a minimum version or range of versions for your module dependencies. Premake includes [a modified version Lua's `require()` function](globals/require.md) which accepts a version test as its second argument.

```lua
require("qt", ">=1.1")
```

See [the `require()` documentation](require.md) for more information and examples.
See [the `require()` documentation](globals/require.md) for more information and examples.
28 changes: 14 additions & 14 deletions website/docs/Whats-New-in-5.0.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,13 +26,13 @@ title: What's New in 5.0
* [Removes](Removing-Values.md)
* [System Scripts](System-Scripts.md)
* [Tokens](Tokens.md)
* [HTTP support](http.download.md)
* [HTTP support](http/http.download.md)

## New or Modified Globals ##

* [_MAIN_SCRIPT](premake_MAIN_SCRIPT.md)
* [_MAIN_SCRIPT_DIR](premake_MAIN_SCRIPT_DIR.md)
* [_PREMAKE_DIR](premake_PREMAKE_DIR.md)
* [_MAIN_SCRIPT](globals/premake_MAIN_SCRIPT.md)
* [_MAIN_SCRIPT_DIR](globals/premake_MAIN_SCRIPT_DIR.md)
* [_PREMAKE_DIR](globals/premake_PREMAKE_DIR.md)

## New or Modified API calls ##

Expand Down Expand Up @@ -127,22 +127,22 @@ title: What's New in 5.0

## New or Modified Lua library calls ##

* [includeexternal](includeexternal.md) (new)
* [require](require.md) (modified)
* [includeexternal](globals/includeexternal.md) (new)
* [require](globals/require.md) (modified)

* [debug.prompt](debug.prompt.md) (new)

* [http.download](http.download.md) (new)
* [http.get](http.get.md) (new)
* [http.download](http/http.download.md) (new)
* [http.get](http/http.get.md) (new)

* [os.chmod](os.chmod.md) (new)
* [os.islink](os.islink.md) (new)
* [os.realpath](os.realpath.md) (new)
* [os.uuid](os.uuid.md) (can now generated deterministic name-based UUIDs)
* [os.chmod](os/os.chmod.md) (new)
* [os.islink](os/os.islink.md) (new)
* [os.realpath](os/os.realpath.md) (new)
* [os.uuid](os/os.uuid.md) (can now generated deterministic name-based UUIDs)

* [path.getabsolute](path.getabsolute.md) (new "relative to" argument)
* [path.getabsolute](path/path.getabsolute.md) (new "relative to" argument)

* [string.hash](string.hash.md) (new)
* [string.hash](string/string.hash.md) (new)

## Deprecated Values and Functions ##

Expand Down
4 changes: 2 additions & 2 deletions website/docs/filter.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,13 +12,13 @@ Any settings that appear after this function in the script will be applied only

Each keyword must include a prefix to specify which field should be tested. The following field prefixes are currently supported:

* [action](premake_ACTION.md)
* [action](globals/premake_ACTION.md)
* [architecture](architecture.md)
* [configurations](configurations.md)
* [files](files.md)
* [kind](kind.md)
* [language](language.md)
* [options](premake_OPTIONS.md)
* [options](globals/premake_OPTIONS.md)
* [platforms](platforms.md)
* [system](system.md)
* [toolset](toolset.md)
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Loading