Skip to content

Commit

Permalink
meta: Bring all ma boi home.
Browse files Browse the repository at this point in the history
  • Loading branch information
sleepy-monax committed Oct 26, 2024
1 parent b64f8a6 commit 3da9382
Show file tree
Hide file tree
Showing 1,337 changed files with 91,876 additions and 9 deletions.
42 changes: 33 additions & 9 deletions project.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,17 +4,41 @@
"type": "project",
"description": "The Skift Operating System",
"extern": {
"skift-org/hideo": {
"git": "https://github.com/skift-org/hideo.git",
"tag": "v0.1.0"
"cute-engineering/ce-heap": {
"git": "https://github.com/cute-engineering/ce-heap.git",
"tag": "v1.1.0"
},
"skift-org/karm": {
"git": "https://github.com/skift-org/karm.git",
"tag": "v0.1.3"
"cute-engineering/ce-mdi": {
"git": "https://github.com/cute-engineering/ce-mdi.git",
"tag": "v0.2.0"
},
"odoo/paper-muncher": {
"git": "https://github.com/odoo/paper-muncher",
"tag": "v0.1.2"
"cute-engineering/ce-libc": {
"git": "https://github.com/cute-engineering/ce-libc.git",
"tag": "v1.1.0"
},
"cute-engineering/ce-libm": {
"git": "https://github.com/cute-engineering/ce-libm.git",
"tag": "v1.0.2"
},
"cute-engineering/ce-stdcpp": {
"git": "https://github.com/cute-engineering/ce-stdcpp.git",
"tag": "v1.3.0"
},
"cute-engineering/cat": {
"git": "https://github.com/cute-engineering/cat.git",
"tag": "v0.7.4"
},
"sdl2": {
"description": "A cross-platform development library designed to provide low level access to hardware",
"names": [
"sdl2"
]
},
"uring": {
"description": "Linux io_uring library",
"names": [
"liburing"
]
}
}
}
17 changes: 17 additions & 0 deletions src/apps/hideo-2048/game.cpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
#include <karm-kira/scaffold.h>
#include <karm-ui/layout.h>
#include <mdi/grid.h>

#include "game.h"

namespace Hideo::H2048 {

Ui::Child game() {
return Kr::scaffold({
.icon = Mdi::GRID,
.title = "2048"s,
.body = slot$(Ui::empty()),
});
}

} // namespace Hideo::H2048
9 changes: 9 additions & 0 deletions src/apps/hideo-2048/game.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
#pragma once

#include <karm-ui/node.h>

namespace Hideo::H2048 {

Ui::Child game();

} // namespace Hideo::H2048
11 changes: 11 additions & 0 deletions src/apps/hideo-2048/main/main.cpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
#include <karm-sys/entry.h>
#include <karm-ui/app.h>

#include "../game.h"

Async::Task<> entryPointAsync(Sys::Context &ctx) {
co_return Ui::runApp(
ctx,
Hideo::H2048::game()
);
}
11 changes: 11 additions & 0 deletions src/apps/hideo-2048/main/manifest.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
{
"$schema": "https://schemas.cute.engineering/stable/cutekit.manifest.component.v1",
"id": "hideo-2048.main",
"props": {
"cpp-excluded": true
},
"type": "exe",
"requires": [
"hideo-2048"
]
}
9 changes: 9 additions & 0 deletions src/apps/hideo-2048/manifest.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
{
"$schema": "https://schemas.cute.engineering/stable/cutekit.manifest.component.v1",
"id": "hideo-2048",
"type": "lib",
"description": "Merge the numbers to get to the 2048 tile!",
"requires": [
"karm-kira"
]
}
57 changes: 57 additions & 0 deletions src/apps/hideo-about/app.cpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,57 @@
#include <karm-base/witty.h>
#include <karm-image/loader.h>
#include <karm-kira/about-dialog.h>
#include <karm-kira/badge.h>
#include <karm-kira/scaffold.h>
#include <karm-sys/time.h>
#include <karm-ui/dialog.h>
#include <karm-ui/input.h>
#include <karm-ui/layout.h>
#include <karm-ui/view.h>
#include <mdi/information.h>
#include <mdi/license.h>

namespace Hideo::About {

Ui::Child app() {
return Kr::scaffold({
.icon = Mdi::INFORMATION,
.title = "About"s,
.titlebar = Kr::TitlebarStyle::DIALOG,
.body =
[] {
auto titleText = Ui::headlineMedium("skiftOS");

auto bodyText =
Ui::bodySmall("Copyright © 2018-2024 The skiftOS Developers\n"
"Copyright © 2024 Odoo S.A.\n"
"\n"
"All rights reserved.");

auto inspireMe = Ui::state(Sys::now().val(), [](auto v, auto bind) {
auto body = Ui::hflow(
8, Math::Align::CENTER,
Ui::image(Image::load("bundle://hideo-about/pride.qoi"_url).unwrap(), 4),
Ui::bodySmall(wholesome(v))
);

return body | Ui::insets({6, 16, 6, 12}) |
Ui::minSize({Ui::UNCONSTRAINED, 36}) |
Ui::button(bind(v + 1), Ui::ButtonStyle::subtle());
});

auto licenseBtn = Ui::button(
[](auto &n) {
Ui::showDialog(n, Kr::licenseDialog());
},
Ui::ButtonStyle::outline(), Mdi::LICENSE, "License"
);

return Ui::vflow(8, Ui::hflow(8, titleText, Kr::versionBadge() | Ui::center()), Ui::empty(), bodyText, Ui::grow(NONE), Ui::hflow(8, inspireMe | Ui::vcenter() | Ui::grow(), licenseBtn)) |
Ui::insets(16);
},
.size = {460, 320},
});
}

} // namespace Hideo::About
9 changes: 9 additions & 0 deletions src/apps/hideo-about/app.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
#pragma once

#include <karm-ui/node.h>

namespace Hideo::About {

Ui::Child app();

} // namespace Hideo::About
8 changes: 8 additions & 0 deletions src/apps/hideo-about/main/main.cpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
#include <karm-sys/entry.h>
#include <karm-ui/app.h>

#include "../app.h"

Async::Task<> entryPointAsync(Sys::Context &ctx) {
co_return Ui::runApp(ctx, Hideo::About::app());
}
11 changes: 11 additions & 0 deletions src/apps/hideo-about/main/manifest.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
{
"$schema": "https://schemas.cute.engineering/stable/cutekit.manifest.component.v1",
"id": "hideo-about.main",
"props": {
"cpp-excluded": true
},
"type": "exe",
"requires": [
"hideo-about"
]
}
9 changes: 9 additions & 0 deletions src/apps/hideo-about/manifest.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
{
"$schema": "https://schemas.cute.engineering/stable/cutekit.manifest.component.v1",
"id": "hideo-about",
"type": "lib",
"description": "About the skift operating system",
"requires": [
"karm-kira"
]
}
Binary file added src/apps/hideo-about/res/pride.qoi
Binary file not shown.
17 changes: 17 additions & 0 deletions src/apps/hideo-apps/app.cpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
#include <karm-kira/scaffold.h>
#include <karm-ui/layout.h>
#include <mdi/basket.h>

#include "app.h"

namespace Hideo::Apps {

Ui::Child app() {
return Kr::scaffold({
.icon = Mdi::BASKET,
.title = "Apps"s,
.body = slot$(Ui::empty()),
});
}

} // namespace Hideo::Apps
9 changes: 9 additions & 0 deletions src/apps/hideo-apps/app.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
#pragma once

#include <karm-ui/node.h>

namespace Hideo::Apps {

Ui::Child app();

} // namespace Hideo::Apps
11 changes: 11 additions & 0 deletions src/apps/hideo-apps/main/main.cpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
#include <karm-sys/entry.h>
#include <karm-ui/app.h>

#include "../app.h"

Async::Task<> entryPointAsync(Sys::Context &ctx) {
co_return Ui::runApp(
ctx,
Hideo::Apps::app()
);
}
11 changes: 11 additions & 0 deletions src/apps/hideo-apps/main/manifest.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
{
"$schema": "https://schemas.cute.engineering/stable/cutekit.manifest.component.v1",
"id": "hideo-apps.main",
"props": {
"cpp-excluded": true
},
"type": "exe",
"requires": [
"hideo-apps"
]
}
9 changes: 9 additions & 0 deletions src/apps/hideo-apps/manifest.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
{
"$schema": "https://schemas.cute.engineering/stable/cutekit.manifest.component.v1",
"id": "hideo-apps",
"type": "lib",
"description": "Install, update, and manage application",
"requires": [
"karm-kira"
]
}
17 changes: 17 additions & 0 deletions src/apps/hideo-avplayer/app.cpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
#include <karm-kira/scaffold.h>
#include <karm-ui/layout.h>
#include <mdi/play-circle.h>

#include "app.h"

namespace Hideo::Avplayer {

Ui::Child app() {
return Kr::scaffold({
.icon = Mdi::PLAY_CIRCLE,
.title = "Media Player"s,
.body = slot$(Ui::empty()),
});
}

} // namespace Hideo::Avplayer
9 changes: 9 additions & 0 deletions src/apps/hideo-avplayer/app.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
#pragma once

#include <karm-ui/node.h>

namespace Hideo::Avplayer {

Ui::Child app();

} // namespace Hideo::Avplayer
11 changes: 11 additions & 0 deletions src/apps/hideo-avplayer/main/main.cpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
#include <karm-sys/entry.h>
#include <karm-ui/app.h>

#include "../app.h"

Async::Task<> entryPointAsync(Sys::Context &ctx) {
co_return Ui::runApp(
ctx,
Hideo::Avplayer::app()
);
}
11 changes: 11 additions & 0 deletions src/apps/hideo-avplayer/main/manifest.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
{
"$schema": "https://schemas.cute.engineering/stable/cutekit.manifest.component.v1",
"id": "hideo-avplayer.main",
"props": {
"cpp-excluded": true
},
"type": "exe",
"requires": [
"hideo-avplayer"
]
}
9 changes: 9 additions & 0 deletions src/apps/hideo-avplayer/manifest.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
{
"$schema": "https://schemas.cute.engineering/stable/cutekit.manifest.component.v1",
"id": "hideo-avplayer",
"type": "lib",
"description": "Play audio and video",
"requires": [
"karm-kira"
]
}
Loading

0 comments on commit 3da9382

Please sign in to comment.