GithubHelp home page GithubHelp logo

jasonwei512 / code-radio-cli Goto Github PK

View Code? Open in Web Editor NEW
343.0 343.0 16.0 591 KB

๐ŸŽต A command line music radio client for https://coderadio.freecodecamp.org, written in Rust.

Home Page: https://crates.io/crates/code-radio-cli

License: MIT License

Rust 100.00%
cli code-radio command-line freecodecamp music music-player rust

code-radio-cli's Introduction

JasonWei512's GitHub stats-Dark JasonWei512's GitHub stats-Light

code-radio-cli's People

Contributors

41leahcim avatar jasonwei512 avatar shnewto avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

code-radio-cli's Issues

GitHub Action: Build ARM64 binary

Currently the GitHub Action build workflow only builds x64 binary. No ARM64 build so far.

Blocking issues

  • GitHub Action doesn't provide ARM64 containers for Windows, Ubuntu and macOS.
  • Cross compilation doesn't work. I tried to build for "aarch64-pc-windows-msvc" in a Windows x64 container, but it failed when compiling "minimp3-sys" crate.
    Related PR: lieff/minimp3#85
    Build log:
    --- stdout
    TARGET = Some("aarch64-pc-windows-msvc")
    OPT_LEVEL = Some("0")
    HOST = Some("x86_64-pc-windows-msvc")
    cargo:rerun-if-env-changed=CC_aarch64-pc-windows-msvc
    CC_aarch64-pc-windows-msvc = None
    cargo:rerun-if-env-changed=CC_aarch64_pc_windows_msvc
    CC_aarch64_pc_windows_msvc = None
    cargo:rerun-if-env-changed=TARGET_CC
    TARGET_CC = None
    cargo:rerun-if-env-changed=CC
    CC = None
    cargo:rerun-if-env-changed=CFLAGS_aarch64-pc-windows-msvc
    CFLAGS_aarch64-pc-windows-msvc = None
    cargo:rerun-if-env-changed=CFLAGS_aarch64_pc_windows_msvc
    CFLAGS_aarch64_pc_windows_msvc = None
    cargo:rerun-if-env-changed=TARGET_CFLAGS
    TARGET_CFLAGS = None
    cargo:rerun-if-env-changed=CFLAGS
    CFLAGS = None
    cargo:rerun-if-env-changed=CRATE_CC_NO_DEFAULTS
    CRATE_CC_NO_DEFAULTS = None
    CARGO_CFG_TARGET_FEATURE = Some("neon")
    DEBUG = Some("true")
    running: "C:\\Program Files (x86)\\Microsoft Visual Studio\\2019\\BuildTools\\VC\\Tools\\MSVC\\14.29.30133\\bin\\HostX64\\arm64\\cl.exe" "-nologo" "-MD" "-Z7" "-Brepro" "-I" "minimp3/" "-W4" "-DMINIMP3_IMPLEMENTATION" "-FoC:\\Users\\USER\\Code\\code-radio-cli\\target\\aarch64-pc-windows-msvc\\debug\\build\\minimp3-sys-946560fc38d54c57\\out\\minimp3.o" "-c" "minimp3.c"
    minimp3.c
    C:\Users\USER\.cargo\registry\src\github.com-1ecc6299db9ec823\minimp3-sys-0.3.2\minimp3\minimp3.h(187): fatal error C1189: #error:  MINIMP3_ONLY_SIMD used, but SSE/NEON not enabled
    exit code: 2
    

Cannot install with cargo in Termux

I have rust installed and have run other rust apps in Termux, but I had this error when trying to install this app with cargo.

error[E0425]: cannot find value EXPECTED_JVM_FILENAME in this scope
--> /data/data/com.termux/files/home/.cargo/registry/src/github.com-1ecc6299db9ec823/jni-0.19.0/build.rs:102:25
|
102 | if file_name == EXPECTED_JVM_FILENAME {
| ^^^^^^^^^^^^^^^^^^^^^ not found in this scope

For more information about this error, try rustc --explain E0425.
error: could not compile jni due to previous error
warning: build failed, waiting for other jobs to finish...
error: failed to compile code-radio-cli v1.0.3, intermediate artifacts can be found at /data/data/com.termux/files/usr/tmp/cargo-installWovW8G

Unable to run it globally, need help in setting up the path or environment variables.

It works in windows, but required me to download the package from github releases, (winget installs but didn't run after, and yes, i started a new shell session.) navigate to the folder where it is saved and also required me to run it like this instead of the "code-radio" command:

Suggestion [3,General]: The command code-radio-1.0.3-windows-x86_64-msvc.exe was not found, but does exist in the current
location. Windows PowerShell does not load commands from the current location by default. If you trust this command, instead type:
".\code-radio-1.0.3-windows-x86_64-msvc.exe". See "get-help about_Command_Precedence" for more details.

I think it has to do something with setting up the path or something, but unable to figure it out. Would appreciate some help.

code-radio : The term 'code-radio' is not recognized as the name of a cmdlet, function, script file, or operable
program. Check the spelling of the name, or if a path was included, verify that the path is correct and try again.
At line:1 char:1

  • code-radio
  •   + CategoryInfo          : ObjectNotFound: (code-radio:String) [], CommandNotFoundException
      + FullyQualifiedErrorId : CommandNotFoundException
    

changing system audio output device requires code-radio restart

Hello! I love this crate! thanks for putting it together ๐Ÿ˜„

I noticed that when code-radio is playing in my terminal (macOS 13.0.1, Intel, iTerm2 Build 3.4.18), if I switch my audio output device, code-radio doesn't play there unless I quit and restart. So for instance, if I'm listening on my laptop speakers then plug in headphones, I have to restart code-radio to get in in the headphones.

By no means is this a big deal for me, it's simple to just restart, but I thought I'd raise the issue in case it's not on the radar.

System Package Dependencies

My environment is Ubuntu 22.04.

https://github.com/rustaudio/cpal

Note that on Linux, the ALSA development files are required. These are provided as part of the libasound2-dev package on Debian and Ubuntu distributions and alsa-lib-devel on Fedora.

It's better to add a link for this.

Getting 404 error

I haven't fired up Code Radio CLI in awhile, but today I'm getting a 404 error when trying to launch the program via MINGW64 and Powershell. I tried downloading a new copy of the 1.03 release, and I'm still having the same 404 error. I can access code radio via the browser, if that is useful information.

I tried using the "-s" flag as well and got this error: "Error: error decoding response body: invalid type: integer 404, expected struct CodeRadioMessage at line 1 column 3"

ARM64 Support

Add support for ARM architecture to make it compatible with Apple's M series processors.

Unable to connect

Got the following response when I tried to stream today

Error: Server-Sent Events Error: HttpStream(
    hyper::Error(
        Connect,
        Custom {
            kind: Other,
            error: Custom {
                kind: InvalidData,
                error: InvalidSCT(
                    UnknownLog,
                ),
            },
        `},`
    ),
)

Multiple crashes

Hello, I've been using it for the last hours, but I keep having crashes, bellow are the logs.

Song:       Luv(sic) Part5  featuring Shing02 instrumental
Artist:     Nujabes
Album:      Luv (Sic) Part 5

Song:       digital dreams
Artist:     knowmadic
Album:      Chillhop Essentials Winter 2019
Volume 1/9  โ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘ 01:16 / 02:52 - Listeners: 141
Error: WebSocket protocol error: Connection reset without closing handshake
Song:       earth angel
Artist:     Marcus D
Album:
Volume 1/9  โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘ 02:57 - Listeners: 126
Error: expected value at line 1 column 1

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.