Code Monkey home page Code Monkey logo

muzik-offline's Introduction





application

muzik-offline

A cross platform, local music player that is an offline(no streaming) version of muzik. This app allows you to listen to music that is stored on your local machine, that being music in mp3, wav, ogg and flac format.

Table of Contents

I am a user/tester

  1. Navigate to the releases tab and find the latest app release for your operating system.
  2. Download it and install and enjoy the application
  3. Please read the usage section for some extra information.
  4. Also note that you can report bugs/issues or make feature requests

Usage

  1. Some shortcuts include
    • SPACE - Pause/Play music
    • CTRL/CMD + SHIFT + F - Open/Close settings
    • CTRL/CMD + S - Focus on search bar
    • CTRL/CMD + I - Show song info
    • UP or DOWN - scroll song by song
    • LEFT or RIGHT - seek by fixed value
    • CTRL/CMD + P or ENTER - Play the selected song
    • CTRL/CMD + SHIFT + A - Add to playlist
    • CTRL/CMD + SHIFT + L - Play later
    • CTRL/CMD + SHIFT + N - Play Next

I am a developer

Development Cycle

  1. Download the pre-requisites for tauri only by following the pre-requisites page for your operating system.
  2. If you are on linux OS(debian/ubuntu), run
sudo apt-get install libasound2-dev
  1. Clone this repo, specifically the main-app-dev branch
  2. run
cd muzik-offline/muzik-offline
  1. run
npm install
  1. This project uses discord rpc, so you will need a client id, otherwise the code won't compile
  2. To get a client id, setup a new application on discord developer portal and then place your client id in an .env file in the src-tauri directory
  3. The env file should look like this:
DISCORD_CLIENT_ID=<Your client id goes here>
  1. If you are on linux/macos or any unix based OS, please navigate to tauri.config.json and under the windows object, change the decorations property to true
  2. run
npm run tauri dev

Building

  1. Clone the releases branch. It is the most stable and ready to go branch
  2. Before you create a build, you will have to embed any env variables into the rust code otherwise the application will panic if you try to run it. The env variables are only meant to be used in the development cycle.
  3. To embed the env variables, copy your DISCORD_CLIENT_ID from the .env file.
  4. Go to discord_rpc.rs and comment out these snippets of code:
3 -> use dotenv::dotenv;
4 -> use std::env;

15 -> //get client id from env variables
16 -> dotenv().ok();
17 -> let client_id = env::var("DISCORD_CLIENT_ID").expect("DISCORD_CLIENT_ID env variable not set");
  1. In this snippet of code let client: DiscordIpcClient = DiscordIpcClient::new(&client_id)?;, replace &client_id with "<Your client id goes here>"
  2. You can also remove the dotnev crate by just removing that line of code.
  3. If you want to go back to dev, you will have to undo all the steps above.
  4. If you want to create a production build, run
npm run tauri build
  1. If you want to create a debug production build(one where you have access to devtools), run
npm run tauri build -- --debug

Please note that when you run npm run tauri dev, npm run tauri build or npm run tauri build -- --debug for the first time, it may take a lengthy amount of minutes to compile everything. However this only occurs just on your first run. In subsequent runs, it will be faster.

Node modules used

  1. tauri-apps/api
  2. dexie
  3. framer motion
  4. react and react-dom
  5. react-router-dom
  6. react viewport list
  7. sass
  8. zustand

Rust libraries used

  1. tauri
  2. serde
  3. serde_json
  4. id3
  5. lofty
  6. tokio
  7. base64
  8. image
  9. kira
  10. rand
  11. rayon
  12. sled
  13. dirs
  14. discord-rich-presence
  15. dotenv

muzik-offline's People

Contributors

waveyboym avatar

Stargazers

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

Watchers

 avatar

Forkers

itsharex

muzik-offline's Issues

[BUG]An empty context menu displays on some pages

Describe the bug
Sometimes an empty context menu displays on some pages when trying to look at the properties of a song, playlist etc.

To Reproduce
Steps to reproduce the behavior:

  1. Click on the searchbar
  2. Backclick on a song and click on properties or type CTRL-SHIFT-I
  3. See the empty context menu

Expected behavior
No context menu should display when a user is just trying to view the properties of a song.

Screenshots
image

Desktop (please complete the following information):

  • OS: Windows
  • Browser: Webview 2
  • Version: 121.0.2277.83

Additional context
None

[BUG]Window becomes undraggable when exiting miniplayer

Describe the bug
If a mini-player is placed at the rightmost position of the computer window and a user goes back to the full sized player and immediately goes to the full screen player mode, and they attempt to drag the window, they may find that they are unable to and are thus forced to close the window and relaunch the application just to use it.

To Reproduce
Steps to reproduce the behavior:

  1. Open the miniplayer
  2. Drag the minplayer to the rightmost part of your computer window, but it must still be within the bounds of your computer window
  3. Go back to the normal player
  4. Before dragging the window, attempt to go to a full screen player
  5. Try dragging the window and observe that you cannot do so since the draggable regions have been hidden.

Expected behavior
The app should never get into a state whereby it is not draggable. It should always be draggable.

Screenshots
None

Desktop (please complete the following information):

  • OS: Windows
  • Browser Webview2
  • Version 121.0.2277.83

Additional context
Since this issue only occurs on variants that use a frameless window, it is tagged as being a windows issue since windows is the only OS that uses frameless windows for this app.

Bug..? app doesnt launch as its supposed to

Describe the bug
Alrighty so idek whats wrong but i followed the basic guide for installing and everything goes through except the app itself doesnt run for sum reason i tried 2 of the windows setup thingys both the msi and setup files but nothing works i did also try running as administrator but even that didnt work..

To Reproduce
Steps to reproduce the behavior:

  1. Download as usual
  2. install
  3. Run app
  4. nothing happens :/

Expected behavior
the app to work as normal lol wit the gui and everything and to jam ofc

Screenshots
If applicable, add screenshots to help explain your problem.

Desktop (please complete the following information):

  • OS:Windows
  • Browser: FireFox i do have chrome as well tho
  • Version i believe this is windows version? i have a custom version of windows but heres the build version 22h2 19045.3803

Additional context
Add any other context about the problem here.

[FEATURE REQUEST] - Run windows executable on macos and linux using wine

Is your feature request related to a problem? Please describe.
It would be nice to offer a guide for users to install the windows executable on macos and linux distro's and run it as if it were native as windows webview seems to be more stable and capable than webkit from both macos and linux.

Describe the solution you'd like
Using wine or bottles would be the best approach

Describe alternatives you've considered
None

Additional context
None

[BUG] Cannot switch off discord connect if discord app is not running

Describe the bug
As the title says, when a user want's to turn off the ability for discord to display their activity, if the discord app is not running, the app sends a notification that it cannot switch off automatic connectivity.

To Reproduce
Steps to reproduce the behavior:

  1. Go to settings
  2. Scroll down to 'Show app activity on dsicrod'
  3. Make sure your discord app is not running
  4. Make sure that the value has already been set to 'Yes'
  5. Attempt to set it to 'No' and observe that it fails to change it even though the expected behavior is for it to turn off.

Expected behavior
When the user attempts to switch off discord connectivity, it should turn off even if the discord app is not running.

Screenshots
Not applicable

Desktop (please complete the following information):

  • OS: Windows 10
  • Browser Webview2
  • Version 121.0.2277.83

Additional context
None

[BUG] Some songs don't autoplay to the next song

Describe the bug
When some songs reach their end, they don't auto-play the next song but rather freeze until the user interacts with the player. This can be disruptive.

To Reproduce
Steps to reproduce the behavior:

  1. Just a play any song, it usually occurs with songs that end with a one, eg "03:21", "02:01"
  2. Seek to at least 10 seconds before the song ends
  3. Observe that when the songs reaches it's end, it does not auto-play the next song.

Expected behavior
When the song reaches it's end, it should auto-play the next song if it is not set to repeat that song.

Screenshots
None

Desktop (please complete the following information):

  • OS: [Windows]
  • Browser [edge]
  • Version [10]

Additional context
None

Song cover disappears from music player when creating a playlist

Describe the bug
When a user navigates to the playlist page and they click on the button that creates a new playlist, and the playlist creation modal shows up, it removes the cover of a song that may be playing. Or even if there is no song playing, the cover still get's removed.

To Reproduce
Steps to reproduce the behavior:

  1. Go to playlist page
  2. Click on create a playlist
  3. See error by looking down at the player and seeing that it no longer has a cover

Expected behavior
A user should be able to open the playlist modal and expect the cover to not disappear

Screenshots
image

Desktop (please complete the following information):

  • OS: Ubuntu
  • Browser: webkitgtk2
  • Version 4.0

Additional context
It has been found that this bug is conditional. It is not always reproducible ,meaning it appears sometimes and other times it does not appear. It does however seem to appear less times than it does not appear.

Multiple notifications sent when loading music from a path

When loading music from a path, a notification saying the task is done however the music has not even been loaded yet but then when the music is actually loaded a bit later, another notification is sent.
The expected behavior should be only one notification being sent after the music has been loaded

Here is a corresponding screenshot:
image

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.