| Top |
Builder supports running in "command-line" mode when executed like "gnome-builder -t cli". If you use Builder from flatpak, this may be activated like "flatpak run org.gnome.Builder -t cli".
We suggest users that want to use this feature often to alias the command in their shell such as "alias ide="gnome-builder -t cli".
When running Builder in this mode, a number of command line tools can be used instead of the full Gtk-based user interface.
Plugins can implement this interface to provide additional command-line tools. To be displayed in user help, you must also specify the name such as "X-Tool-Name=foo" in your plugin's .plugin manifest. You should also provide "X-Tool-Description=description" to notify the user of what the tool does.
void ide_application_tool_run_async (IdeApplicationTool *self,const gchar * const *arguments,GCancellable *cancellable,GAsyncReadyCallback callback,gpointer user_data);
Asynchronously runs an application tool. This is typically done on the
command line using the ide command.
self |
||
arguments |
argv for the command. |
[array zero-terminated=1][element-type utf8] |
cancellable |
a GCancellable or |
[nullable] |
callback |
A callback to execute upon completion |
|
user_data |
User data for |
Since: 3.22
gint ide_application_tool_run_finish (IdeApplicationTool *self,GAsyncResult *result,GError **error);
Completes an asynchronous request to ide_application_tool_run_async().
This should return an exit code (were 0 is success) and set error
when non-zero.
The exit code shall be returned to the calling shell.
Since: 3.22
struct IdeApplicationToolInterface {
GTypeInterface parent_interface;
void (*run_async) (IdeApplicationTool *self,
const gchar * const *arguments,
GCancellable *cancellable,
GAsyncReadyCallback callback,
gpointer user_data);
gint (*run_finish) (IdeApplicationTool *self,
GAsyncResult *result,
GError **error);
};
Use this interface to implement a command-line tool for Builder that can be accessed when running builder in command-line mode using "gnome-builder -t cli".
GTypeInterface |
||
You must implement this virtual function as part of running your command line operation. |
||
You must implement this virtual function as part of running your command line operation. |
Since: 3.22