-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Set up UI for the final presentation See merge request jesture/jestureui!4
- Loading branch information
Showing
74 changed files
with
3,438 additions
and
1,076 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
{ | ||
"version": "2.0.0", | ||
"tasks": [ | ||
{ | ||
"label": "Build jesture (dbg)", | ||
"type": "shell", | ||
"command": "bazel", | ||
"args": [ | ||
"build", | ||
"--compilation_mode=dbg", | ||
"//jesture" | ||
], | ||
"presentation": { | ||
"reveal": "silent" | ||
}, | ||
"group": { | ||
"kind": "build", | ||
"isDefault": false | ||
} | ||
} | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,23 +1,77 @@ | ||
config_setting ( | ||
name = "linux", | ||
constraint_values = [ | ||
"@platforms//os:linux" | ||
], | ||
visibility = ["//visibility:public"] | ||
load("//distribution:dist_vars.bzl", "dist_vars") | ||
load("@rules_pkg//pkg:mappings.bzl", "pkg_attributes", "pkg_files", "pkg_mklink") | ||
load("@rules_pkg//pkg:deb.bzl", "pkg_deb") | ||
load("@rules_pkg//pkg:tar.bzl", "pkg_tar") | ||
|
||
# distribution( | ||
# name = "dist", | ||
# bin = "//jesture", | ||
# deb_package_desc = "TODO", | ||
# deb_package_name = "jesture", | ||
# maintainer = "TODO", | ||
# product_name = "jesture", | ||
# version = "0.5.0", | ||
# ) | ||
|
||
VERSION = "0.5.0" | ||
|
||
dist_vars( | ||
name = "jesture_dist_vars", | ||
arch = select({ | ||
"@platforms//cpu:x86_64": "x86_64", | ||
"//conditions:default": "UNKNOWN", | ||
}), | ||
product_name = "jesture", | ||
version = VERSION, | ||
) | ||
|
||
config_setting ( | ||
name = "windows", | ||
constraint_values = [ | ||
"@platforms//os:windows" | ||
pkg_files( | ||
name = "jesture_linux_bin", | ||
srcs = ["//jesture"], | ||
attributes = pkg_attributes( | ||
mode = "0551", | ||
), | ||
prefix = "/opt/jesture", | ||
) | ||
|
||
pkg_files( | ||
name = "jesture_linux_models", | ||
srcs = ["//jesture:models"], | ||
prefix = "/opt/jesture/models", | ||
) | ||
|
||
pkg_mklink( | ||
name = "jesture_linux_usr_bin", | ||
link_name = "/usr/bin/jesture", | ||
target = "/opt/jesture/jesture", | ||
) | ||
|
||
pkg_tar( | ||
name = "jesture_linux_tar", | ||
srcs = [ | ||
":jesture_linux_bin", | ||
":jesture_linux_models", | ||
":jesture_linux_usr_bin", | ||
], | ||
visibility = ["//visibility:public"] | ||
package_file_name = "{product_name}-{version}-{arch}-linux.tar", | ||
package_variables = ":jesture_dist_vars", | ||
) | ||
|
||
config_setting ( | ||
name = "macos", | ||
constraint_values = [ | ||
"@platforms//os:macos" | ||
pkg_deb( | ||
name = "jesture_deb", | ||
data = ":jesture_linux_tar", | ||
description = "TODO", | ||
maintainer = "", | ||
package = "jesture", | ||
package_file_name = "{product_name}-{version}-{arch}.deb", | ||
package_variables = ":jesture_dist_vars", | ||
version = VERSION, | ||
) | ||
|
||
filegroup( | ||
name = "distribution", | ||
srcs = [ | ||
":jesture_deb", | ||
":jesture_linux_tar", | ||
], | ||
visibility = ["//visibility:public"] | ||
) | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
# Development Requirements | ||
* [Bazel](https://bazel.build/) | ||
|
||
# IDE setup | ||
For any IDEs using some form of `clangd` for IntelliSense run | ||
``` | ||
bazel run //.vscode:compile_commands | ||
``` | ||
to generate a `compile_commands.json` file. | ||
|
||
## VSCode | ||
VSCode is the preferred IDE as we have setup some tooling to make working in this | ||
code base easier. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
""" | ||
TODO | ||
""" | ||
|
||
load("@rules_pkg//pkg:providers.bzl", "PackageVariablesInfo") | ||
load("@rules_cc//cc:find_cc_toolchain.bzl", "find_cc_toolchain") | ||
|
||
def _dist_vars_impl(ctx): | ||
values = {} | ||
|
||
# cc_toolchain = find_cc_toolchain(ctx) | ||
|
||
values["product_name"] = ctx.attr.product_name | ||
values["version"] = ctx.attr.version.replace(".", "_") | ||
|
||
values["arch"] = ctx.attr.arch | ||
|
||
return PackageVariablesInfo(values = values) | ||
|
||
dist_vars = rule( | ||
implementation = _dist_vars_impl, | ||
attrs = { | ||
"product_name": attr.string( | ||
doc = "Placeholder for our final product name.", | ||
), | ||
"version": attr.string( | ||
doc = "Placeholder for our release version.", | ||
), | ||
"arch": attr.string(), | ||
"_cc_toolchain": attr.label( | ||
default = Label( | ||
"@rules_cc//cc:current_cc_toolchain", | ||
), | ||
), | ||
}, | ||
toolchains = ["@rules_cc//cc:toolchain_type"], | ||
incompatible_use_toolchain_transition = True, | ||
) |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,41 @@ | ||
load("//qt:qt.bzl", "qt_resource") | ||
|
||
package(default_visibility = ["//visibility:public"]) | ||
|
||
exports_files([ | ||
"jesture.svg", | ||
"jesture.ico", | ||
"settings.svg", | ||
"settings.png", | ||
"show.svg", | ||
"show.png", | ||
"hide.svg", | ||
"quit.svg", | ||
"hide.png", | ||
"add.svg", | ||
"add.png", | ||
"add_element.svg", | ||
"add_element.png", | ||
"cross.svg", | ||
"left_arrow.svg", | ||
"add.svg" | ||
]) | ||
"cross.png" | ||
]) | ||
|
||
qt_resource( | ||
name = "icons", | ||
files = { | ||
"jesture.svg": ":jesture.svg", | ||
"jesture.ico": ":jesture.ico", | ||
"settings.svg": ":settings.svg", | ||
"settings.png": ":settings.png", | ||
"show.svg": ":show.svg", | ||
"show.png": ":show.png", | ||
"hide.svg": ":hide.svg", | ||
"hide.png": ":hide.png", | ||
"add.svg": ":add.svg", | ||
"add.png": ":add.png", | ||
"add_element.svg": ":add_element.svg", | ||
"add_element.png": ":add_element.png", | ||
"cross.svg": ":cross.svg", | ||
"cross.png": ":cross.png" | ||
}, | ||
prefix = "/jesture/icons", | ||
) |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file not shown.
Oops, something went wrong.