Skip to content

Commit

Permalink
Release v1.0.1
Browse files Browse the repository at this point in the history
Set title to filename instead of filepath in the UI
Change title in the video render page
  • Loading branch information
dormant-user committed Feb 21, 2024
1 parent ce5ba14 commit 6427a5c
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 10 deletions.
2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "RuStream"
version = "1.0.0"
version = "1.0.1"
description = "Self-hosted Streaming Engine, that can render videos via authenticated sessions."
license = "MIT"
documentation = "https://docs.rs/RuStream"
Expand Down
10 changes: 5 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -58,8 +58,6 @@ curl -o RuStream-Windows-x86_64.zip -LH "Accept: application/octet-stream" "http
</details>

#### Environment Variables
> Environment variables can (optionally) be loaded from any plain text file.<br>
> Refer the [wiki page][gh-wiki-env] for more information.

**Mandatory**
- **authorization**: Dictionary of key-value pairs with `username` as key and `password` as value.
Expand All @@ -80,6 +78,8 @@ curl -o RuStream-Windows-x86_64.zip -LH "Accept: application/octet-stream" "http
> If `SECURE_SESSION` is to set to `true`, the cookie `session_token` will only be sent via HTTPS<br>
> This means that the server can **ONLY** be hosted via `HTTPS` or `localhost`
> Checkout [GitHub Wiki][gh-wiki-env] for more information about environment variables and `dotenv` usage.
## Crate
[https://crates.io/crates/RuStream][crate]

Expand All @@ -91,9 +91,6 @@ curl -o RuStream-Windows-x86_64.zip -LH "Accept: application/octet-stream" "http
cargo doc --document-private-items --no-deps
```

### GitHub Wiki - Project Insights
[https://github.com/thevickypedia/RuStream/wiki][gh-wiki]

## Linting
### Requirement
```shell
Expand All @@ -104,6 +101,9 @@ rustup component add clippy
cargo clippy --no-deps --fix
```

## GitHub Wiki - Project Insights
[https://github.com/thevickypedia/RuStream/wiki][gh-wiki]

## License & copyright

&copy; Vignesh Rao
Expand Down
6 changes: 3 additions & 3 deletions src/routes/video.rs
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,7 @@ pub async fn stream(config: web::Data<Arc<squire::settings::Config>>,
// Rust doesn't allow re-assignment, so might as well create a mutable variable
// Load the default response body and re-construct with subtitles if present
let mut response_body = landing.render(context!(
video_title => &filepath, path => render_path,
video_title => &__filename, path => render_path,
previous => &rust_iter.previous,
next => &rust_iter.next,
previous_title => &rust_iter.previous,
Expand All @@ -149,7 +149,7 @@ pub async fn stream(config: web::Data<Arc<squire::settings::Config>>,
if subtitle.vtt.exists() {
let sfx_file = format!("/track?file={}", url_encode(&subtitle.vtt_file));
response_body = landing.render(context!(
video_title => &filepath, path => render_path,
video_title => &__filename, path => render_path,
previous => &rust_iter.previous,
next => &rust_iter.next,
previous_title => &rust_iter.previous,
Expand All @@ -165,7 +165,7 @@ pub async fn stream(config: web::Data<Arc<squire::settings::Config>>,
log::debug!("Successfully converted srt to vtt file");
let sfx_file = format!("/track?file={}", url_encode(&subtitle.vtt_file));
response_body = landing.render(context!(
video_title => &filepath, path => render_path,
video_title => &__filename, path => render_path,
previous => &rust_iter.previous,
next => &rust_iter.next,
previous_title => &rust_iter.previous,
Expand Down
2 changes: 1 addition & 1 deletion src/templates/landing.rs
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ pub fn get_content() -> String {
<html lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title>Rustic video streaming</title>
<title>{{ video_title }}</title>
<meta property="og:type" content="VideoStreaming">
<meta name="keywords" content="Rust, streaming, actix, JavaScript, HTML, CSS">
<meta name="author" content="Vignesh Rao">
Expand Down

0 comments on commit 6427a5c

Please sign in to comment.