diff --git a/hosts/yodaTab/configuration.nix b/hosts/yodaTab/configuration.nix index 56238d0..3087163 100644 --- a/hosts/yodaTab/configuration.nix +++ b/hosts/yodaTab/configuration.nix @@ -10,6 +10,7 @@ ../../modules/base-efi.nix ../../modules/xdg.nix ../../modules/power-management.nix + ../../modules/usb-mtp-ptp.nix ../../modules/ntfs.nix ../../modules/git.nix ../../modules/zsh.nix diff --git a/hosts/yodaTux/configuration.nix b/hosts/yodaTux/configuration.nix index 5ce8927..a5573c2 100644 --- a/hosts/yodaTux/configuration.nix +++ b/hosts/yodaTux/configuration.nix @@ -11,6 +11,7 @@ ../../modules/base-efi.nix ../../modules/xdg.nix ../../modules/power-management.nix + ../../modules/usb-mtp-ptp.nix ../../modules/tuxedo-rs.nix ../../modules/ntfs.nix ../../modules/git.nix diff --git a/modules/usb-mtp-ptp.nix b/modules/usb-mtp-ptp.nix new file mode 100644 index 0000000..b981767 --- /dev/null +++ b/modules/usb-mtp-ptp.nix @@ -0,0 +1,21 @@ +{ config, pkgs, ... }: +{ + # USB MTP and PTP support + # https://wiki.archlinux.org/title/Media_Transfer_Protocol#File_manager_integration + + # Mount USB MTP devices + services.gvfs.enable = true; + + # Manage USB PTP devices (digital cameras) + programs.gphoto2.enable = true; + # To grant digital camera access to a user, + # the user must be part of the camera group: + users.users."yoda".extraGroups = ["camera"]; + # + # Example usage: + # + # gphoto2 --auto-detect + #=> Fuji Fujifilm X-T1 usb:001,002 + # gphoto2 --list-files + # gphoto2 --get-all-files +}