Giter Club home page Giter Club logo

library-loader's Introduction

Library Loader ๐Ÿ“š

Status: Build Status

Getting started

  1. Create an account on componentsearchengine.com if you don't have one already.
  2. Download a prebuilt version of library-loader from the releases page (only linux builds available, see #67).

Simple install / uninstall

On the releases page, download the latest library-loader-linux-dist.tar.gz and untar it. Each release is bundled with two scripts for installing and uninstalling library-loader :

# Installs both cli/gui binaries in `/usr/bin`
# Installs desktop entry and icon for `library-loader-gui`
sudo install.sh

# Uninstall `library-loader` completely
sudo uninstall.sh

Building from source using Docker

This allows you to build without installing any dependencies on your machine.

docker run --volume=$(pwd):/home/circleci/project olback/rust-gtk-linux cargo build --release

Building from source locally(macOS)

Required binaries: brew(from homebrew), rustc, cargo You have to install rust via rustup and initialize it with rustup-init command.

./macos-compile.sh

Setup on macOS

Edit the LibraryLoader.example.toml and fill in your login details for componentsearchengine.com. Rename the file to LibraryLoader.toml and place it in ~/Library/Application Support/LibraryLoader.toml.

e.g.

cp LibraryLoader.example.toml ~/Library/Application\ Support/LibraryLoader.toml"

Running on macOS

GUI:

cargo run --bin library-loader-gui

or CLI:

cargo run --bin library-loader-cli

What/Why?

This is an implementation of https://www.samacsys.com/library-loader/ in Rust. Why? Well, since the library-loader SamacSys provides only works on Windows, I thought it would be neat to make something similar but available to everyone.

For upcomming features, please see the TODO.md.

License

GNU Affero General Public License v3.0

library-loader's People

Contributors

4c0n avatar cgreening avatar iamphytan avatar kms1212 avatar olback avatar simonlovskog 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  avatar

library-loader's Issues

macOS Monterey ARM64 install errors out with Package 'libjpeg', required by 'gdk-pixbuf-2.0', not found

Running the install script macos-compile.sh results in an error message when executing the following:
$CARGO build --release --target=aarch64-apple-darwin
The error is:

  cargo:warning=`"pkg-config" "--libs" "--cflags" "gdk-pixbuf-2.0" "gdk-pixbuf-2.0 >= 2.32"` did not exit successfully: exit status: 1
  --- stderr
  Package libjpeg was not found in the pkg-config search path.
  Perhaps you should add the directory containing `libjpeg.pc'
  to the PKG_CONFIG_PATH environment variable
  Package 'libjpeg', required by 'gdk-pixbuf-2.0', not found

warning: build failed, waiting for other jobs to finish...

The solution is to brew install jpeg. After manually running the following:
brew install jpeg
and rerunning the install script macos-compile.sh, everything works perfectly fine.

installs ok but fails to do the job - Ubuntu 20.04

Hello;

Runs but for some reasons it does not succeed to download right; Thanks

peter@on7yi-ubuntu:~/Downloads/library-loader-0.2.2$ ./library-loader-gui
Starting watcher thread
Starting...
=> Detected: /home/peter/Downloads/LIB_LTC1569CS8-6#PBF(1).zip
=> Detected: /home/peter/Downloads/LIB_LTC1569CS8-6#PBF(1).zip
=> Error: Error downloading file: 401 Unauthorized
=> Error: Error downloading file: 401 Unauthorized

image

3D Models

It would be nice to also extract the 3D Models if available.

Kind Regards,
Stefan

error: failed to run custom build command for `library-loader-gui v0.2.2 (/Users/liam/library-loader/ll-gui)

Hello,
I'm trying to install this to macOS Catalina and every time I try, this error message comes up. Not sure if this is just an issue on my mac or what.

error: failed to run custom build command for library-loader-gui v0.2.2 (/Users/liam/library-loader/ll-gui)`

Caused by:
process didn't exit successfully: /Users/liam/library-loader/target/release/build/library-loader-gui-8e406340802ffbdf/build-script-build (exit code: 101)
--- stdout
cargo:rerun-if-changed=.git/HEAD
cargo:rerun-if-changed=assets/*

--- stderr
thread 'main' panicked at 'Command 'glib-compile-resources' not found', ll-gui/build/resources.rs:11:9
note: run with RUST_BACKTRACE=1 environment variable to display a backtrace
warning: build failed, waiting for other jobs to finish...
error: build failed`

Use rustls

Use rustls instead of openssl to avoid errors on some systems.

How do you launch the app?

Hi,

Forgive my ignorance... I have successfully build the ll-gui, everything went well, but now I don't know how to launch the app. I have tried running library-loader-gui.desktop but it just launches GIMP...

I'm on MacOS 11.3.2 (Big Sur).

Many thanks for your help!
Harold

No 3D models

I'm not sure what's going on, but when using KiCad mode the downloaded files don't contain stp files. I can see that the footprint files (.kicad_mod) refer to a .stp file, but it is nowhere to be found.

Process KiCad output

It would be great if you could process the KiCad Output so it is more useful to KiCad Users:

  • Copy *.kicad_mod files into seperate folder
  • *.mod files are not needed for recent KiCad Versions as far as i know
  • concat all *.lib files together
  • concat all *.dcm files together

I wrote a small bash script for the necessary steps, but i dont know how to do it in rust:

#!/bin/bash

LIBRARY="LibraryLoader.lib"
DOCLIB="LibraryLoader.dcm"
FOOTPRINT_FOLDER="LibraryLoader.pretty"

#Add static Lines at beginning of Library and Doclib File
echo 'EESchema-LIBRARY Version 2.3' > ${LIBRARY}
echo '#encoding utf-8' >> ${LIBRARY}
echo 'EESchema-DOCLIB  Version 2.0' > ${DOCLIB}

echo Footprint Folder: ${FOOTPRINT_FOLDER}

if [ ! -d ${FOOTPRINT_FOLDER} ]; then
mkdir ${FOOTPRINT_FOLDER}
fi

for d in *; do
  if [ -d ${d} ]; then # test if it is a directory or file
  	if [ ${d} != ${FOOTPRINT_FOLDER} ]; then # skip Footprint Folder itself
      echo processing $d ...
      # copy footprint to footprint folder
      cp -av ${d}/*.kicad_mod ${FOOTPRINT_FOLDER} 
      # concat all chars between DEF and ENDDEF to Library file
      cat ${d}/*.lib | sed -e '1h;2,$H;$!d;g' -re 's/.*(DEF.*ENDDEF).*/\1/g' >> ${LIBRARY}
      # concat all chars between $CMP and ENDCMP to Doclib file
      cat ${d}/*.dcm | sed -e '1h;2,$H;$!d;g' -re 's/.*(\$CMP.*ENDCMP).*/\1/g' >> ${DOCLIB}
    fi
  fi
done

Non-fatal warnings during build on MacOS

During the cargo build step on MacOS, the following block of non-fatal warnings is emitted:

  --> ll-gui/build/resources.rs:11:16
   |
11 |         panic!(format!("Command '{}' not found", COMMAND));
   |                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
   |
   = note: `#[warn(non_fmt_panic)]` on by default
   = note: this is no longer accepted in Rust 2021
   = note: the panic!() macro supports formatting, so there's no need for the format!() macro here
help: remove the `format!(..)` macro call
   |
11 |         panic!("Command '{}' not found", COMMAND);
   |               --                               --

warning: panic message is not a string literal
  --> ll-gui/build/resources.rs:20:16
   |
20 |         panic!(format!("Failed to generate resources: {}", String::from_utf8_lossy(&resources.stderr)))
   |                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
   |
   = note: this is no longer accepted in Rust 2021
   = note: the panic!() macro supports formatting, so there's no need for the format!() macro here
help: remove the `format!(..)` macro call
   |
20 |         panic!("Failed to generate resources: {}", String::from_utf8_lossy(&resources.stderr))
   |               --                                                                            --

warning: 2 warnings emitted

(To be clear, I have no idea what any of this means, but it seemed like something you should be told about.)

handle error when componentsearchengine's terms and conditions change

Every now and then, the Samacsys' componentsearchengines Terms and Conditions change. Upon login on their site, one is prompted to read and agree/disagree to their updated Terms and Conditions.

The library loader failed with the error "Error downloading file: Could not determine content type". It took me quite some time to figure out what the problem was, as i wrongly suspected a bug in the library loader.

A simple solution was to implement a check, as the model.php (as in const 'COMPONENT_SEARCH_ENGINE_URL') simply returns this plain text string in such case:

Error: Our terms and conditions have changed. You need to log in at https://componentsearchengine.com and accept the new terms before downloading models.

install.sh fails on macOS

On MacOS Big Sur, after running all prior build-from-source steps successfully, attempting sudo ./install.sh gives
cp: /usr/bin/library-loader-gui: Operation not permitted
cp: directory /usr/share/applications does not exist
cp: /usr/share/icons/hicolor/scalable/apps/net.olback.LibraryLoader.svg: No such file or directory
This appears to be because the install.sh is designed for Linux.

Crashing when attempting to load components.

Faulting application name: Library Loader.exe, version: 2.49.0.0, time stamp: 0x6038d6d2
Faulting module name: KERNELBASE.dll, version: 10.0.19041.1566, time stamp: 0x0833f2d4
Exception code: 0xe0434352
Fault offset: 0x0000000000034f69
Faulting process id: 0xf38
Faulting application start time: 0x01d84ae8ad161878
Faulting application path: C:\Program Files (x86)\SamacSys\Library Loader\Library Loader.exe
Faulting module path: C:\WINDOWS\System32\KERNELBASE.dll
Report Id: d2b46c24-c577-41da-a577-9ae70f8a29fe
Faulting package full name:
Faulting package-relative application ID:

Only able to find this in application events log. No error appears just a critical crash and Library Loader is terminated and errors show in application logs at the time of crash. Not sure what is needed to get better logs from the app. I will look into code to see if it is possible to debug

Failing to compile on macOS with error ```E0433```

Rust is installed using: curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh Compilation fails with:

error[E0433]: failed to resolve: could not find `line` in `std`
  --> src/main.rs:38:87
   |
38 |                 eprintln!("{}#{}: Error checking for updates: {}", std::file!(), std::line!(), e);
   |                                                                                       ^^^^ could not find `line` in `std`

error: aborting due to 41 previous errors

Is this problem with environment or with source itself?
Thank you

gui fails to compile on macos

I have a fresh install of rust toolchain (not a rust dev)
cli compiled OK
building gui failed at with

   ...
   Compiling glib-macros v0.10.0
   Compiling gdk-sys v0.10.0
   Compiling atk-sys v0.10.0
   Compiling gtk-sys v0.10.0
   Compiling library-loader-gui v0.2.2 (/Users/neil/code/library-loader/ll-gui)
error: failed to run custom build command for `glib-sys v0.10.0`

Caused by:
  process didn't exit successfully: `/Users/neil/code/library-loader/target/release/build/glib-sys-a440839a206d2de1/build-script-build` (exit code: 1)
--- stderr
Failed to run `"pkg-config" "--libs" "--cflags" "glib-2.0" "glib-2.0 >= 2.42"`: No such file or directory (os error 2)

warning: build failed, waiting for other jobs to finish...
error: build failed

I have pkgbuild pkgutil in my path but no pkg-config - I don't knpw anything about packaging but thought I'd flag the error, great project!

Watcher should ignore Firefoxes *.zip.part files while downloading

When using Firefox to download a part library from - let's say mouser.com - the watcher (within the GUI) throws an error
Error: invalid digit found in string while the file is still downloading (and has the *.part ending on the disk).
Once the file is downloaded and gets renamed from XXX.zip.part to XXX.zip however, the watcher no longer detects it as new file.
This basically renders the watcher useless when using Firefox.

error: failed to run custom build command for `pango-sys v0.10.0`

Hi,

I have the following issue at the end of the gui build:

warning: panic message is not a string literal
  --> ll-gui/build/resources.rs:11:16
   |
11 |         panic!(format!("Command '{}' not found", COMMAND));
   |                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
   |
   = note: `#[warn(non_fmt_panic)]` on by default
   = note: this is no longer accepted in Rust 2021
   = note: this warning originates in a macro (in Nightly builds, run with -Z macro-backtrace for more info)

warning: panic message is not a string literal
  --> ll-gui/build/resources.rs:20:16
   |
20 |         panic!(format!("Failed to generate resources: {}", String::from_utf8_lossy(&resources.stderr)))
   |                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
   |
   = note: this is no longer accepted in Rust 2021
   = note: this warning originates in a macro (in Nightly builds, run with -Z macro-backtrace for more info)

warning: 2 warnings emitted

error: failed to run custom build command for `pango-sys v0.10.0`

Caused by:
  process didn't exit successfully: `/Users/stephanemuller/Downloads/AD5171BRJZ100-R7-pcb-part-libraries/library-loader/target/release/build/pango-sys-cc8383c5b3ea0f8e/build-script-build` (exit code: 1)
  --- stderr
  `"pkg-config" "--libs" "--cflags" "pango" "pango >= 1.36"` did not exit successfully: exit code: 1
  --- stderr
  Package pango was not found in the pkg-config search path.
  Perhaps you should add the directory containing `pango.pc'
  to the PKG_CONFIG_PATH environment variable
  No package 'pango' found
  Package pango was not found in the pkg-config search path.
  Perhaps you should add the directory containing `pango.pc'
  to the PKG_CONFIG_PATH environment variable
  No package 'pango' found

warning: build failed, waiting for other jobs to finish...
error: build failed

I'm on MacOS Big Sur 11.3.2.

Many thanks for your help!

Error on installation error: linking with `cc` failed: exit code: 1

Hi,

I'm on MacOS 11.2.3 (Big Sur) and when I try to compile cli or gui version I get the following error:

error: linking with `cc` failed: exit code: 1

|
  = note: "cc" "-m64" "-arch" "x86_64" "-L" "/Users/stephanemuller/.rustup/toolchains/stable-x86_64-apple-darwin/lib/rustlib/x86_64-apple-darwin/lib" "/Users/stephanemuller/Downloads/AD5171BRJZ100-R7-pcb-part-libraries/library-loader/target/release/build/memchr-1d6269df49c7ee42/build_script_build-1d6269df49c7ee42.build_script_build.1fjwt4ys-cgu.0.rcgu.o" "/Users/stephanemuller/Downloads/AD5171BRJZ100-R7-pcb-part-libraries/library-loader/target/release/build/memchr-1d6269df49c7ee42/build_script_build-1d6269df49c7ee42.build_script_build.1fjwt4ys-cgu.1.rcgu.o" "/Users/stephanemuller/Downloads/AD5171BRJZ100-R7-pcb-part-libraries/library-loader/target/release/build/memchr-1d6269df49c7ee42/build_script_build-1d6269df49c7ee42.build_script_build.1fjwt4ys-cgu.10.rcgu.o" "/Users/stephanemuller/Downloads/AD5171BRJZ100-R7-pcb-part-libraries/library-loader/target/release/build/memchr-1d6269df49c7ee42/build_script_build-1d6269df49c7ee42.build_script_build.1fjwt4ys-cgu.11.rcgu.o" "/Users/stephanemuller/Downloads/AD5171BRJZ100-R7-pcb-part-libraries/library-loader/target/release/build/memchr-1d6269df49c7ee42/build_script_build-1d6269df49c7ee42.build_script_build.1fjwt4ys-cgu.12.rcgu.o" "/Users/stephanemuller/Downloads/AD5171BRJZ100-R7-pcb-part-libraries/library-loader/target/release/build/memchr-1d6269df49c7ee42/build_script_build-1d6269df49c7ee42.build_script_build.1fjwt4ys-cgu.13.rcgu.o" "/Users/stephanemuller/Downloads/AD5171BRJZ100-R7-pcb-part-libraries/library-loader/target/release/build/memchr-1d6269df49c7ee42/build_script_build-1d6269df49c7ee42.build_script_build.1fjwt4ys-cgu.14.rcgu.o" "/Users/stephanemuller/Downloads/AD5171BRJZ100-R7-pcb-part-libraries/library-loader/target/release/build/memchr-1d6269df49c7ee42/build_script_build-1d6269df49c7ee42.build_script_build.1fjwt4ys-cgu.15.rcgu.o" "/Users/stephanemuller/Downloads/AD5171BRJZ100-R7-pcb-part-libraries/library-loader/target/release/build/memchr-1d6269df49c7ee42/build_script_build-1d6269df49c7ee42.build_script_build.1fjwt4ys-cgu.2.rcgu.o" "/Users/stephanemuller/Downloads/AD5171BRJZ100-R7-pcb-part-libraries/library-loader/target/release/build/memchr-1d6269df49c7ee42/build_script_build-1d6269df49c7ee42.build_script_build.1fjwt4ys-cgu.3.rcgu.o" "/Users/stephanemuller/Downloads/AD5171BRJZ100-R7-pcb-part-libraries/library-loader/target/release/build/memchr-1d6269df49c7ee42/build_script_build-1d6269df49c7ee42.build_script_build.1fjwt4ys-cgu.4.rcgu.o" "/Users/stephanemuller/Downloads/AD5171BRJZ100-R7-pcb-part-libraries/library-loader/target/release/build/memchr-1d6269df49c7ee42/build_script_build-1d6269df49c7ee42.build_script_build.1fjwt4ys-cgu.5.rcgu.o" "/Users/stephanemuller/Downloads/AD5171BRJZ100-R7-pcb-part-libraries/library-loader/target/release/build/memchr-1d6269df49c7ee42/build_script_build-1d6269df49c7ee42.build_script_build.1fjwt4ys-cgu.6.rcgu.o" "/Users/stephanemuller/Downloads/AD5171BRJZ100-R7-pcb-part-libraries/library-loader/target/release/build/memchr-1d6269df49c7ee42/build_script_build-1d6269df49c7ee42.build_script_build.1fjwt4ys-cgu.7.rcgu.o" "/Users/stephanemuller/Downloads/AD5171BRJZ100-R7-pcb-part-libraries/library-loader/target/release/build/memchr-1d6269df49c7ee42/build_script_build-1d6269df49c7ee42.build_script_build.1fjwt4ys-cgu.8.rcgu.o" "/Users/stephanemuller/Downloads/AD5171BRJZ100-R7-pcb-part-libraries/library-loader/target/release/build/memchr-1d6269df49c7ee42/build_script_build-1d6269df49c7ee42.build_script_build.1fjwt4ys-cgu.9.rcgu.o" "-o" "/Users/stephanemuller/Downloads/AD5171BRJZ100-R7-pcb-part-libraries/library-loader/target/release/build/memchr-1d6269df49c7ee42/build_script_build-1d6269df49c7ee42" "/Users/stephanemuller/Downloads/AD5171BRJZ100-R7-pcb-part-libraries/library-loader/target/release/build/memchr-1d6269df49c7ee42/build_script_build-1d6269df49c7ee42.2nxwh6audqwzng4q.rcgu.o" "-Wl,-dead_strip" "-nodefaultlibs" "-L" "/Users/stephanemuller/Downloads/AD5171BRJZ100-R7-pcb-part-libraries/library-loader/target/release/deps" "-L" "/Users/stephanemuller/.rustup/toolchains/stable-x86_64-apple-darwin/lib/rustlib/x86_64-apple-darwin/lib" "/Users/stephanemuller/.rustup/toolchains/stable-x86_64-apple-darwin/lib/rustlib/x86_64-apple-darwin/lib/libstd-349f286494d73b18.rlib" "/Users/stephanemuller/.rustup/toolchains/stable-x86_64-apple-darwin/lib/rustlib/x86_64-apple-darwin/lib/libpanic_unwind-0c9fcc24a503d489.rlib" "/Users/stephanemuller/.rustup/toolchains/stable-x86_64-apple-darwin/lib/rustlib/x86_64-apple-darwin/lib/libobject-70419d92d1ba4b1d.rlib" "/Users/stephanemuller/.rustup/toolchains/stable-x86_64-apple-darwin/lib/rustlib/x86_64-apple-darwin/lib/libaddr2line-65e88774cb68bd46.rlib" "/Users/stephanemuller/.rustup/toolchains/stable-x86_64-apple-darwin/lib/rustlib/x86_64-apple-darwin/lib/libgimli-3849b3781a19a398.rlib" "/Users/stephanemuller/.rustup/toolchains/stable-x86_64-apple-darwin/lib/rustlib/x86_64-apple-darwin/lib/librustc_demangle-0dbb03fa66ca6d84.rlib" "/Users/stephanemuller/.rustup/toolchains/stable-x86_64-apple-darwin/lib/rustlib/x86_64-apple-darwin/lib/libhashbrown-65edff8661311c85.rlib" "/Users/stephanemuller/.rustup/toolchains/stable-x86_64-apple-darwin/lib/rustlib/x86_64-apple-darwin/lib/librustc_std_workspace_alloc-599e707cd7ee7216.rlib" "/Users/stephanemuller/.rustup/toolchains/stable-x86_64-apple-darwin/lib/rustlib/x86_64-apple-darwin/lib/libunwind-40cb05f6c516791a.rlib" "/Users/stephanemuller/.rustup/toolchains/stable-x86_64-apple-darwin/lib/rustlib/x86_64-apple-darwin/lib/libcfg_if-7a0a923a4d37a048.rlib" "/Users/stephanemuller/.rustup/toolchains/stable-x86_64-apple-darwin/lib/rustlib/x86_64-apple-darwin/lib/liblibc-7e047938e88325ef.rlib" "/Users/stephanemuller/.rustup/toolchains/stable-x86_64-apple-darwin/lib/rustlib/x86_64-apple-darwin/lib/liballoc-02542d835be27c0f.rlib" "/Users/stephanemuller/.rustup/toolchains/stable-x86_64-apple-darwin/lib/rustlib/x86_64-apple-darwin/lib/librustc_std_workspace_core-63712b18a1365082.rlib" "/Users/stephanemuller/.rustup/toolchains/stable-x86_64-apple-darwin/lib/rustlib/x86_64-apple-darwin/lib/libcore-1196a2a060497e71.rlib" "/Users/stephanemuller/.rustup/toolchains/stable-x86_64-apple-darwin/lib/rustlib/x86_64-apple-darwin/lib/libcompiler_builtins-10db70d883838cbc.rlib" "-lSystem" "-lresolv" "-lc" "-lm"
  = note: xcrun: error: invalid active developer path (/Library/Developer/CommandLineTools), missing xcrun at: /Library/Developer/CommandLineTools/usr/bin/xcrun

What can I do to fix it?

Many thanks!!

Invalid archive files

Hi when downloading from component search engine (e.g. a 741 amp ) I receive the following errors -

[INFO] Started watching "/Users/peckc/Downloads"
[INFO] Active formats:
[INFO] 	zip => "/Users/peckc/Documents/KiCadLibraries/ComponentSearchEngine"
[INFO] Detected "/Users/peckc/Downloads/LIB_UA741CDRG4.zip.download/LIB_UA741CDRG4.zip"
[ERROR] Zip(InvalidArchive("Could not find central directory end"))
[INFO] Detected "/Users/peckc/Downloads/LIB_UA741CDRG4.zip.download/LIB_UA741CDRG4.zip"
[ERROR] Io(Os { code: 2, kind: NotFound, message: "No such file or directory" })
[INFO] Detected "/Users/peckc/Downloads/LIB_UA741CDRG4.zip.download/LIB_UA741CDRG4.zip"
[ERROR] Io(Os { code: 2, kind: NotFound, message: "No such file or directory" })

Running macosMonteray 12.1 x86_64

[Edited by olback - fixed formatting]

Failed to get default download dir

I'm getting the following error while trying to generate default config file:

>> library-loader-cli -g -u
Writing default config to "/home/ms/.config/LibraryLoader.toml"
thread 'main' panicked at 'Failed to get default download dir', ll-core/src/config/mod.rs:93:22
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace

It seems to fail on dirs::download_dir function. According to Rust docs return value should depend on XDG_DOWNLOAD_DIR environment variable.

I verified if it's present and it was. To be sure I also tried running it with the path set explicitly:

>> XDG_DOWNLOAD_DIR=/home/ms/Downloads library-loader-cli -g -u
Writing default config to "/home/ms/.config/LibraryLoader.toml"
thread 'main' panicked at 'Failed to get default download dir', ll-core/src/config/mod.rs:93:22
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace

error when installing "error: failed to compile `library-loader v0.1.2 (/home/pi)`, intermediate artifacts can be found at `/home/pi/target`"

hi, i have bad issues when trying to install it

during the compilling process i have

error[E0599]: no function or associated item named `new` found for trait object `dyn notify::Watcher` in the current scope
  --> src/watcher.rs:28:62
   |
28 |         let w: notify::RecommendedWatcher = notify::Watcher::new(tx.clone(), Duration::from_secs(2))?;
   |                                                              ^^^ function or associated item not found in `dyn notify::Watcher`

error: aborting due to previous error

For more information about this error, try `rustc --explain E0599`.
error: failed to compile `library-loader v0.1.2 (/home/pi)`, intermediate artifacts can be found at `/home/pi/target`

Caused by:
  could not compile `library-loader`.

To learn more, run the command again with --verbose.

i don't know why...

Multiple output formats or 3d checkbox/button

Is outputting both format Kicad and format 3D possible in the current release version ?

Tried comma and space separation for format = 'kicad, 3d' no luck
Tried launching multiple instances of library-loader-gui also no luck

As for now workflow is: output zip format, extract 3D from zip, extract KiCad from zip, delete zip.
Maybe it would be possible to add a output 3D checkbox/radiobutton besides the format dropdown?

Showing "ZipArchiveEmpty" for libraries that should be OK

I encountered a number of Parts (via mouser.com) where the library-loader GUI says "ZipArchiveEmpty", however when downloading the file via componentsearchengine.com the zip-files look like valid zip files and the desired library is indeed included.
Example:
RAC10E-12SK/277 Recom Power Module
fails via mouser.com (Eagle library).

Install script/package for MacOS - Help wanted

The cli version should work on both M1 and Intel macs without any issues if compiled locally. The GUI version should work on Intel Macs if all GTK dependencies are installed. As far as I know, GTK for Arm on Mac is not a thing yet.

Related issues:
#64

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.