Skip to content

Commit

Permalink
more pages
Browse files Browse the repository at this point in the history
  • Loading branch information
mariotaku committed Jun 12, 2024
1 parent ed6da19 commit a0c8e9f
Show file tree
Hide file tree
Showing 11 changed files with 201 additions and 38 deletions.
23 changes: 23 additions & 0 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 2 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,8 @@
"handlebars": "^4.7.8",
"html-bundler-webpack-plugin": "^3.13.0",
"html-loader": "^5.0.0",
"marked": "^13.0.0",
"marked-alert": "^2.0.1",
"postcss-loader": "^8.1.1",
"sass": "^1.76.0",
"sass-loader": "^14.2.1",
Expand Down
Binary file added src/img/screenshots/devman.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Empty file added src/pages/devmode.md
Empty file.
81 changes: 81 additions & 0 deletions src/pages/rooting.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,81 @@
# Root your TV

## Root or Not?

Before rooting your TV, please think about what you would like to do with a rooted TV.

| Use Case | Root Required |
|-------------------------------------------------|---------------|
| Using Kodi | No |
| Stream PC games with Moonlight | No |
| Amblight setup | Yes |
| Remapping remote control buttons | Yes |
| Keeping Kodi's `.kodi` directory on a USB drive | Yes |

Use Kodi? That doesn't require root.

Stream PC games with Moonlight? That doesn't require root either.

For many uses, like installing some useful homebrew applications, root is **NOT** required.
Using developer mode is enough most of the time and not hard to set up either.
It requires an account though, and you'll have to renew the developer mode every
1000 hours.

However, an Amblight setup with
[PicCap](https://github.com/TBSniller/piccap)/[Hyperion](https://github.com/webosbrew/hyperion-webos)/[HyperHDR](https://github.com/webosbrew/hyperhdr-webos-loader)
*will* require root.

Remapping remote control buttons with [lginputhook](https://github.com/Simon34545/lginputhook) requires root.

Keeping Kodi's `.kodi` directory on a USB drive also requires root.

> [!NOTE]
> Highlights information that users should take into account, even when skimming.
> [!TIP]
> Optional information to help a user be more successful.
> [!IMPORTANT]
> Crucial information necessary for users to succeed.
> [!WARNING]
> Critical content demanding immediate user attention due to potential risks.
> [!CAUTION]
> Negative potential consequences of an action.
### Benefits of Rooting

* No developer mode needed anymore - No need to worry about the dev mode timer or an LG account
* Gain more control over your TV - Block ads and auto-updates
* Increase privacy - Disable telemetry
* More modifications - Custom wallpaper, screensaver, ambient lighting, etc.
* Access webOS internals - Useful for researching and exploring the Linux system underlying webOS

### Caveats of Rooting

* Methods may get patched by LG - If you apply firmware updates, you may lose any homebrew apps and mods you've
installed
* Rooting is safe, but reckless changes are not - You could brick your TV if you don't have proper knowledge and ignore
**[warnings](https://rootmy.tv/warning)**

## How Do I Use Homebrew Apps Without Root?

Using [dev-manager-desktop](https://github.com/webosbrew/dev-manager-desktop) makes this pretty easy.

<img src="https://user-images.githubusercontent.com/830358/215523117-0fdbde24-a503-4eed-8e2f-50a3486ce7f7.png" alt="Install from webOS Homebrew repo" title="Install from webOS Homebrew repo" width="70%">

## I Want Root Anyway!

As of February 2024, LG has released multiple patches for the vulnerabilities we found.
Depending on the firmware and model, there are multiple approaches to rooting a webOS TV.

- [RootMy.TV](https://rootmy.tv/) - For webOS 3.4 and up, but very likely patched (read
the [README](https://github.com/RootMyTV/RootMyTV.github.io?tab=readme-ov-file#readme) first!)
- [crashd](https://gist.github.com/throwaway96/e811b0f7cc2a705a5a476a8dfa45e09f) - For webOS 4.0 and up; patches being
rolled out
- [WTA](https://gist.github.com/throwaway96/b171240ef59d7f5fd6fb48fc6dfd2941) - For webOS 5 and up; patches being rolled
out
- [DEBUG via NVM](https://gist.github.com/throwaway96/827ff726981cc2cbc46a22a2ad7337a1) - Works on all webOS versions
prior to 4.0 (plus NetCast/GP) but requires opening up the TV (no permanent hardware modifications)
- GetMeIn - May work on webOS up to 3.4 on certain models, but don't use the original binary from the XDA thread
44 changes: 24 additions & 20 deletions src/views/index/index.hbs
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>Home | webOS Homebrew</title>
<link href="index.scss" rel="stylesheet">
<link href="../../img/hbchannel-color.svg" type="image/svg" rel="icon">
<link href="@img/hbchannel-color.svg" type="image/svg" rel="icon">
</head>
<body data-bs-theme="dark">
{{> navbar }}
Expand Down Expand Up @@ -142,11 +142,11 @@
</div>

<h3 class="ps-4 position-absolute top-0 bottom-0 align-content-center pointer-events-none">
<img src="../../img/app-icons/org.xbmc.kodi.png" class="app-icon me-2"/>Kodi
<img src="../../img/app-icons/org.xbmc.kodi.png" class="app-icon me-2" alt="Kodi icon"/>Kodi
<br>
<img src="../../img/app-icons/com.limelight.webos.png" class="app-icon me-2"/>Moonlight
<img src="../../img/app-icons/com.limelight.webos.png" class="app-icon me-2" alt="Moonlight icon"/>Moonlight
<br>
<img src="../../img/app-icons/com.retroarch.png" class="app-icon me-2"/>RetroArch
<img src="../../img/app-icons/com.retroarch.png" class="app-icon me-2" alt="RetroArch icon"/>RetroArch
<br>
And ✨more✨
<br>
Expand All @@ -169,9 +169,9 @@
<h3 class="card-title">
Setup with a few steps,<br>
safe and simple.<br>
<a class="text-decoration-none stretched-link" href="#get-started">Get started<i
class="bi bi-chevron-double-right small"></i></a>
</h3>
<a class="text-decoration-none text-primary-emphasis stretched-link h4" href="#get-started">Get started<i
class="bi bi-chevron-double-right small"></i></a>
</div>
</div>
</div>
Expand All @@ -182,19 +182,19 @@
<section id="mods" class="container-lg py-5">
<h2 class="text-center">Gain More Control</h2>
<div class="row g-3 mt-5">
<div class="col-md-6 aspect-ratio-3by2">
<div class="col-sm-6 aspect-ratio-3by2">
<div
class="card border-0 rounded-4 h-100 bg-dark-subtle d-flex flex-column justify-content-end overflow-hidden">
<img class="card-img-top object-fit-contain" src="../../img/screenshots/aerial-screensaver.png"
<img class="card-img-top object-fit-cover" src="../../img/screenshots/aerial-screensaver.png"
alt="Screensaver"/>
<div class="card-body p-4">
<div class="card-body px-4">
<h3 class="card-title">Screensavers</h3>
</div>
</div>
</div>
<div class="col-md-6 aspect-ratio-3by2">
<div class="col-sm-6 aspect-ratio-3by2">
<div class="card border-0 rounded-4 h-100 bg-dark-subtle overflow-hidden">
<img class="card-img object-fit-contain" src="../../img/photos/amblight-setup.jpg" alt="Amblight setup"/>
<img class="card-img object-fit-cover" src="../../img/photos/amblight-setup.jpg" alt="Amblight setup"/>
<div class="card-img-overlay p-4">
<h3 class="card-title">Ambient light</h3>
</div>
Expand All @@ -208,12 +208,6 @@

<div class="py-3 bg-dark-subtle"></div>

<section id="community" class="container-lg py-5">
<h2 class="text-center">Powered by the Community</h2>
</section>

<div class="py-3 bg-dark-subtle"></div>

<section id="get-started" class="container-lg py-5">
<h2 class="text-center">Get Started</h2>
<div class="row g-3 mt-5">
Expand All @@ -227,7 +221,7 @@
<br>
Gain more control over your TV.
</p>
<a class="stretched-link card-link text-white-50" href="https://www.webosbrew.org/rooting">
<a class="stretched-link card-link text-white-50" href="/rooting">
Read tutorial
</a>
</div>
Expand All @@ -242,7 +236,7 @@
<br>
No root required.
</p>
<a class="stretched-link card-link text-white-50" href="https://www.webosbrew.org/rooting">
<a class="stretched-link card-link text-white-50" href="/devmode">
Read tutorial
</a>
</div>
Expand All @@ -253,7 +247,17 @@
<div class="py-3 bg-dark-subtle"></div>

<section id="devman" class="container-lg py-5">
TODO: Banner featuring Dev Manager
<div class="card border-0 rounded-4 p-4 bg-devman overflow-hidden">
<div class="row mx-0">
<div class="col-md-6 ps-0 pe-0 pe-md-3 pb-4">
<h3 class="card-title">Manage your TV with your computer and smartphone</h3>
<a class="stretched-link text-decoration-none h4 opacity-75"
href="https://github.com/webosbrew/dev-manager-desktop">
More info<i class="bi bi-chevron-double-right small"></i></a>
</div>
<img class="col-md-6 devman-screenshot" src="../../img/screenshots/devman.png" alt="DevMan for webOS"/>
</div>
</div>
</section>

<div class="py-3 bg-dark-subtle"></div>
Expand Down
8 changes: 8 additions & 0 deletions src/views/index/index.scss
Original file line number Diff line number Diff line change
Expand Up @@ -120,6 +120,10 @@ html {
background-image: linear-gradient(135deg, rgb(129, 18, 19), rgb(145, 32, 33), rgb(187, 62, 63));
}

.bg-devman {
background-image: linear-gradient(135deg, rgb(2, 116, 167) 30%, rgb(2, 133, 193) 55%, rgb(3, 169, 244));
}

.marquee {
overflow: hidden;
position: relative;
Expand Down Expand Up @@ -200,3 +204,7 @@ html {
.text-pink-500 {
color: $pink-500;
}

.devman-screenshot {
margin-bottom: -10%;
}
19 changes: 19 additions & 0 deletions src/views/page/page.hbs
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>{{title}} | webOS Homebrew</title>
<link href="../../scss/styles.scss" rel="stylesheet">
<link href="@img/hbchannel-color.svg" type="image/svg" rel="icon">
</head>
<body data-bs-theme="dark">
{{> navbar }}
<main class="bg-dark-subtle">
<div class="container py-4">
{{markdown (include page)}}
</div>
</main>
{{> footer }}
</body>
</html>
21 changes: 8 additions & 13 deletions src/views/partials/footer.html
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,17 @@
<img class="bi" width="32" height="32" src="@img/icon32.svg" alt="webOS Homebrew">
<small class="d-block mb-3 text-body-secondary">© 2020–2024</small>
</div>
<div class="col-6 col-md">
<h5>Guides</h5>
<ul class="list-unstyled text-small">
<li><a class="link-secondary text-decoration-none" href="/rooting">Root your TV</a></li>
<li><a class="link-secondary text-decoration-none" href="/devmode">Developer Mode</a></li>
</ul>
</div>
<div class="col-6 col-md">
<h5>Resources</h5>
<ul class="list-unstyled text-small">
<li><a class="link-secondary text-decoration-none" href="#">Business</a></li>
<li><a class="link-secondary text-decoration-none" href="#">Education</a></li>
<li><a class="link-secondary text-decoration-none" href="#">Government</a></li>
<li><a class="link-secondary text-decoration-none" href="#">Gaming</a></li>
<li><a class="link-secondary text-decoration-none" href="#">Documentation</a></li>
</ul>
</div>
<div class="col-6 col-md">
Expand All @@ -25,14 +29,5 @@ <h5>Links</h5>
</li>
</ul>
</div>
<div class="col-6 col-md">
<h5>About</h5>
<ul class="list-unstyled text-small">
<li><a class="link-secondary text-decoration-none" href="#">Team</a></li>
<li><a class="link-secondary text-decoration-none" href="#">Locations</a></li>
<li><a class="link-secondary text-decoration-none" href="#">Privacy</a></li>
<li><a class="link-secondary text-decoration-none" href="#">Terms</a></li>
</ul>
</div>
</div>
</footer>
4 changes: 2 additions & 2 deletions src/views/partials/navbar.html
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<nav class="navbar navbar-expand-md bg-dark sticky-top border-bottom">
<div class="container">
<a class="navbar-brand d-md-none" href="#">
<img class="bi" width="32" height="32" src="../../img/icon32.svg" alt="webOS Homebrew"/>
<img class="bi" width="32" height="32" src="@img/icon32.svg" alt="webOS Homebrew"/>
webOS Homebrew
</a>
<button class="navbar-toggler" type="button" data-bs-toggle="offcanvas" data-bs-target="#offcanvas"
Expand All @@ -16,7 +16,7 @@ <h5 class="offcanvas-title" id="offcanvasLabel">webOS Homebrew</h5>
<div class="offcanvas-body">
<ul class="navbar-nav flex-grow-1 justify-content-start">
<li class="nav-item"><a class="nav-link" href="#">
<img class="bi" width="32" height="32" src="../../img/icon32.svg" alt="webOS Homebrew"/>
<img class="bi" width="32" height="32" src="@img/icon32.svg" alt="webOS Homebrew"/>
</a></li>
<li class="nav-item"><a class="nav-link" href="#">Apps</a></li>
<li class="nav-item"><a class="nav-link" href="#">Develop</a></li>
Expand Down
37 changes: 34 additions & 3 deletions webpack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,10 @@

const path = require('path');
const HtmlBundlerPlugin = require('html-bundler-webpack-plugin');
const { FaviconsBundlerPlugin } = require('html-bundler-webpack-plugin/plugins');
const {FaviconsBundlerPlugin} = require('html-bundler-webpack-plugin/plugins');
const {SafeString} = require('handlebars');
const marked = require('marked');
const markedAlert = require("marked-alert");

module.exports = {
mode: 'development',
Expand All @@ -17,13 +20,41 @@ module.exports = {
index: {
import: './src/views/index/index.hbs',
},
rooting: {
import: './src/views/page/page.hbs',
filename: 'rooting/index.html',
data: {
title: 'Rooting',
page: 'src/pages/rooting.md'
}
},
devmode: {
import: './src/views/page/page.hbs',
filename: 'devmode/index.html',
data: {
title: 'Developer Mode',
page: 'src/pages/devmode.md'
}
}
},
preprocessor: 'handlebars',
preprocessorOptions: {
root: 'src/views',
root: 'src',
partials: [
'src/views/partials'
]
],
helpers: {
'markdown': (string) => {
let html = marked.use(markedAlert({
className: 'alert',
})).parse(typeof string === 'string' ? string : string.string, {
async: false,
gfm: true,
breaks: false,
});
return new SafeString(html);
},
}
},
loaderOptions: {
sources: [{
Expand Down

0 comments on commit a0c8e9f

Please sign in to comment.