Linux instructions

This commit is contained in:
Michael Bucari-Tovo 2022-07-24 16:14:34 -06:00
parent 3fc1da66de
commit 6de3a8a2bf
2 changed files with 73 additions and 9 deletions

View File

@ -30,7 +30,7 @@ namespace LibationAvalonia
public static IAssetLoader AssetLoader { get; private set; }
public static readonly Uri AssetUriBase = new Uri("avares://Libation/Assets/");
public static System.IO.Stream OpenAsset(string assetRelativePath)
public static Stream OpenAsset(string assetRelativePath)
=> AssetLoader.Open(new Uri(AssetUriBase, assetRelativePath));
@ -47,7 +47,7 @@ namespace LibationAvalonia
var startInfo = new System.Diagnostics.ProcessStartInfo()
{
FileName = "/bin/xdg-open",
Arguments = path is null ? string.Empty : $"\"{System.IO.Path.GetDirectoryName(path)}\"",
Arguments = path is null ? string.Empty : $"\"{path}\"",
UseShellExecute = false, //Import in Linux environments
CreateNoWindow = false,
RedirectStandardOutput = true,
@ -89,12 +89,16 @@ namespace LibationAvalonia
config.SetLibationFiles(defaultLibationFilesDir);
if (config.LibationSettingsAreValid)
return;
var setupDialog = new SetupDialog { Config = config };
setupDialog.Closing += Setup_Closing;
desktop.MainWindow = setupDialog;
{
LibraryTask = Task.Run(() => DbContexts.GetLibrary_Flat_NoTracking(includeParents: true));
ShowMainWindow(desktop);
}
else
{
var setupDialog = new SetupDialog { Config = config };
setupDialog.Closing += Setup_Closing;
desktop.MainWindow = setupDialog;
}
}
else
ShowMainWindow(desktop);
@ -129,7 +133,8 @@ namespace LibationAvalonia
MessageBox.VerboseLoggingWarning_ShowIfTrue();
#if !DEBUG
checkForUpdate();
//AutoUpdater.NET only works for WinForms or WPF application projects.
//checkForUpdate();
#endif
// logging is init'd here
AppScaffolding.LibationScaffolding.RunPostMigrationScaffolding(setupDialog.Config);

View File

@ -0,0 +1,59 @@
# Run Libation on Ubuntu
## Dependencies
### Dotnet Runtime
You must install the dotnet 6.0 runtime on your machine.
First, add the Microsoft package signing key to your list of trusted keys and add the package repository.
<details>
<summary>Ubuntu 22.04</summary>
```console
wget https://packages.microsoft.com/config/ubuntu/22.04/packages-microsoft-prod.deb -O packages-microsoft-prod.deb
sudo dpkg -i packages-microsoft-prod.deb
rm packages-microsoft-prod.deb
```
</details>
<details>
<summary>Ubuntu 21.10</summary>
```console
wget https://packages.microsoft.com/config/ubuntu/21.10/packages-microsoft-prod.deb -O packages-microsoft-prod.deb
sudo dpkg -i packages-microsoft-prod.deb
rm packages-microsoft-prod.deb
```
</details>
<details>
<summary>Ubuntu 20.04</summary>
```console
wget https://packages.microsoft.com/config/ubuntu/20.04/packages-microsoft-prod.deb -O packages-microsoft-prod.deb
sudo dpkg -i packages-microsoft-prod.deb
rm packages-microsoft-prod.deb
```
</details>
Then install the dotnet 6.0 runtime
```console
sudo apt-get update; \
sudo apt-get install -y apt-transport-https && \
sudo apt-get update && \
sudo apt-get install -y dotnet-runtime-6.0
```
### FFMpeg (Optional)
If you want to convert your audiobooks to mp3, install FFMpeg using the following command:
```console
sudo apt-get install -y ffmpeg
```
## Install Libation
1. Download and extract the most recent linux-64 build.
2. Run Libation, either from the terminal or by double-clicking the Libation file in your desktop environment.
3. Follow the prompts to setup your installation.
4. Report bugs to https://github.com/rmcrackan/Libation/issues