Skip to main content

os.rename

Rename file system files or directories.

os.rename("path","newpath")

Parameters

path is the file system path to be renamed. newpath is the renamed file system path.

Return Value

True if successful, otherwise nil and an error message.

Availability

Premake 5.0 or later.

See Also

Examples

local ok, err = os.rename{"file.bak","file.log"}
ifnot ok then
error(err)
end

AltStyle によって変換されたページ (->オリジナル) /