I would like to create a file that when double clicked launches a website in the default web browser. I have found that .desktop
files can do this, but apparently they no longer work in Ubuntu 22.04.
How can this be done?
I would like to create a file that when double clicked launches a website in the default web browser. I have found that .desktop
files can do this, but apparently they no longer work in Ubuntu 22.04.
How can this be done?
I regularly use the "right click → open in remote terminal" functionality of Nautilus in Ubuntu 22.04. I don't know the command, but it seems it is doing ssh blah@host
, and I would like to add the -X
flag so I can open GUI applications from this terminal. How can I modify it?
After using Xubuntu (18.04, 20.04) I recently got a new PC and installed Ubuntu 22.04. For some reason some apps just cannot open files in a remote PC mounted via SFTP. Some other apps they just can.
I have found out that the apps suggested in the right click menu are the ones that can open the files. For example in the following right click menu all LibreOffice Writer, Text Editor (gedit) and Zotero) can open remote files:
but Geany and Sublime they can't. The same menu but now on a local file (on local files everything is working perfectly):
If in the remote file I do right click → open with and select Geany or any other app, it fails. The same if I run the command in the terminal:
$ geany sftp://me@remote/home/me_in_remote/file.txt
Could not find file 'sftp://me@remote/home/me_in_remote/file.txt'.
If instead of geany
I use gedit
now it works.
What could be the issue?
I need to install a software (iCEcube2 from Lattice Semiconductor) on a Ubuntu 20.04 machine. Apparently there is something hardcoded in this software related to license checking that requires the computer to be connected to the internet via a connection with name "eth0" (link). I have tried creating the file /etc/udev/rules.d/70-persistent-net.rules
with the following content
SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTR{address}=="XX:XX:XX:XX:XX:XX", ATTR{dev_id}=="0x0", ATTR{type}=="1", NAME="eth0"
where XX:XX:XX:XX:XX:XX
is actually my MAC address. After this I restarted the computer. It does not work. I also tried the method described in the link before under the title License checkout failed: hostid of this system does not match the hostid.
The option 1. in this SO answer, i.e. sudo ip link set wlp2s0 name eth0
works, however it is temporal.
I have an app which I can run from the terminal in this way
python3 /home/me/path/to/my_app.py
It works fine.
To make it easier for other people I want to use the Menu Editor to create a launcher for this. I have done this hundreds of times in the past for other apps, but this one fails and I don't know why. This is my setup:
If I enable Run in terminal the terminal is opened for some milliseconds and then it closes, probably because of an error but there is no time to read what is going on. If I copy-paste the command into a terminal it works fine.
I have a Logitech T400. This mouse has two "middle click buttons":
Button A is mapped to the regular middle click, which is what I want. But button B is mapped to Super L which is useless, I want to map it also to the regular middle click too. I am using Ubuntu 20.04.
I looked into this question of someone asking the same. None of the answers worked for me. I also tried
xmodmap -e "keycode 133 = Pointer_Button2"
as suggested here which also did not worked and I lost the real Super L button in the keyboard which I would like to conserve.
I have tried with the application Input Remapper with this configuration: and it works as I want, but it breaks the soft scroll of the mouse so it is not a solution to me.
If I run xev
then one click and release of button A produces this:
ButtonPress event, serial 37, synthetic NO, window 0x5e00001,
root 0x7b2, subw 0x0, time 886786, (68,93), root:(939,1634),
state 0x0, button 2, same_screen YES
ButtonRelease event, serial 37, synthetic NO, window 0x5e00001,
root 0x7b2, subw 0x0, time 887362, (68,93), root:(939,1634),
state 0x200, button 2, same_screen YES
and one click and release of button B produces this:
MappingNotify event, serial 37, synthetic NO, window 0x0,
request MappingKeyboard, first_keycode 8, count 248
KeyPress event, serial 37, synthetic NO, window 0x5e00001,
root 0x7b2, subw 0x0, time 893980, (68,93), root:(939,1634),
state 0x0, keycode 133 (keysym 0xffeb, Super_L), same_screen YES,
XLookupString gives 0 bytes:
XmbLookupString gives 0 bytes:
XFilterEvent returns: False
KeyRelease event, serial 38, synthetic NO, window 0x5e00001,
root 0x7b2, subw 0x0, time 894604, (68,93), root:(939,1634),
state 0x40, keycode 133 (keysym 0xffeb, Super_L), same_screen YES,
XLookupString gives 0 bytes:
XFilterEvent returns: False
How can I remap button B to "regular middle click" and (if possible) keep Super L working in my keyboard? If no extra apps/programs have to be installed for such simple task, better.
I have a Logitech M600 mouse working in Ubuntu 20.04. I would like to have smooth scrolling instead of "discrete scrolling", i.e. the same type of scrolling I have in my touchpad. How can I do this? Note that I am not talking about changing the acceleration, the speed, the inertia, etc.
I have a lab equipment (CAEN DT1470ET) connected via USB to a Ubuntu 20.04 machine. I have installed the graphical interface software from the manufacturer and it connects properly with the instrument. However, when I try to do it with Python, I can't.
This is my code:
import serial
import time
CAEN = serial.Serial(
port = '/dev/ttyACM0',
baudrate = 9600,
parity = serial.PARITY_NONE,
stopbits = 1,
bytesize = 8,
xonxoff = True,
timeout = 1,
)
command = 'BD:0,CMD:MON,PAR:BDFREL\r\n'.encode('ASCII')
print(f'Sending: {command}')
CAEN.write(command)
time.sleep(1)
print(f'Reading...')
print(CAEN.read(111))
The problem is in the line CAEN.read
. It always goes to the timeout so it always prints b''
(i.e. empty answer), and if the timeout=1
line is removed it stays there indefinitely.
If I run udevadm info -r -q all /dev/ttyACM0
I get:
$ udevadm info -r -q all /dev/ttyACM0
P: /devices/pci0000:00/0000:00:14.0/usb1/1-1/1-1:1.0/tty/ttyACM0
N: ttyACM0
L: 0
S: serial/by-path/pci-0000:00:14.0-usb-0:1:1.0
S: serial/by-id/usb-CAEN_SPA_NIM_Desktop_HV_Power_Supply-if00
E: DEVPATH=/devices/pci0000:00/0000:00:14.0/usb1/1-1/1-1:1.0/tty/ttyACM0
E: DEVNAME=/dev/ttyACM0
E: MAJOR=166
E: MINOR=0
E: SUBSYSTEM=tty
E: USEC_INITIALIZED=17958516201
E: ID_BUS=usb
E: ID_VENDOR_ID=21e1
E: ID_MODEL_ID=0003
E: ID_PCI_CLASS_FROM_DATABASE=Serial bus controller
E: ID_PCI_SUBCLASS_FROM_DATABASE=USB controller
E: ID_PCI_INTERFACE_FROM_DATABASE=XHCI
E: ID_VENDOR_FROM_DATABASE=Intel Corporation
E: ID_VENDOR=CAEN_SPA
E: ID_VENDOR_ENC=CAEN\x20SPA
E: ID_MODEL=NIM_Desktop_HV_Power_Supply
E: ID_MODEL_ENC=NIM\x2fDesktop\x20HV\x20Power\x20Supply
E: ID_REVISION=0100
E: ID_SERIAL=CAEN_SPA_NIM_Desktop_HV_Power_Supply
E: ID_TYPE=generic
E: ID_USB_INTERFACES=:020201:0a0000:
E: ID_USB_INTERFACE_NUM=00
E: ID_USB_DRIVER=cdc_acm
E: ID_USB_CLASS_FROM_DATABASE=Communications
E: ID_PATH=pci-0000:00:14.0-usb-0:1:1.0
E: ID_PATH_TAG=pci-0000_00_14_0-usb-0_1_1_0
E: ID_MM_CANDIDATE=1
E: DEVLINKS=/dev/serial/by-path/pci-0000:00:14.0-usb-0:1:1.0 /dev/serial/by-id/usb-CAEN_SPA_NIM_Desktop_HV_Power_Supply-if00
E: TAGS=:systemd:
I have already set the permissions to the serial port with sudo chmod 666 /dev/ttyACM0
. What am I doing wrong?
I am facing a very annoying behavior in Xubuntu, and I have been experiencing this since many versions (I think 16.04 is when I switched to Xubuntu) with many different computers so this problem has to be very common. Surprisingly I did not found questions/answers in Google about this so I ask here.
When I click/right-click the icons next to the clock in the panel the menu appears below the mouse pointer. Because of this, sometimes the option that appears just below the pointer is accidentally clicked (even by doing a single click) and this is very annoying. Usually this option is to close the corresponding app, but it can be anything. In this link you can see a video with the problem I have. I did not manage to make the apps to accidentally close in the video, but you see the "exit" button appears just below the pointer. Is there any easy solution for this? Like adding a constant offset to the menus, or adding a constant delay time of about 333 ms.
https://www.youtube.com/watch?v=sAIdvNg628c&feature=youtu.be
Yesterday I installed Xubuntu 20.04 in an HP ProBook 430 G7. Today I joined a Zoom meeting and cannot hear the audio, no matter what I try. As can be seen in the pictures below, the Zoom stream "has sound" (the orange bar moves as people speaks) and it is directed to the HDMI3/DP3 output (I don't exactly know what this is, why are there 3 HDMI audio outputs?). If I try to redirect the Zoom audio stream to the Speaker+Headphones (as is the Firefox stream, which works perfectly) it does nothing. I mean, if I click where the mouse is in picture 2, nothing happens. I have tried to unplug the HDMI screen, same result. I have tried to plug the headphones in the screen headphone connector, no audio at all there. Ideas?
Recently I installed Ubuntu 20.04, and then Okular. In my previous Ubuntu 18.04 I often used Okular to render markdown files. Now it is not rendering these format. Do I have to install something extra?
Is it possible to run a GUI program and tell bash to not show the window? E.g. something like nogui firefox
that runs Firefox but don't show the GUI window.
Let me explain my situation: I am processing some images with the program ds9. I have a bash script that opens an image in .fits format format with this program, then export it as .jpeg and then closes the program. It is working perfectly fine. However, each time I run this script, the GUI window of ds9 opens up, then exports the image and then closes. This is annoying when converting many images because there are windows opening an closing automatically for each image.
I am running Xubuntu 18.04 in a desktop computer, installed last week. I am having problems to open files if the path has a blank space and I believe this is producing other problems too (for example this). Just to give an example, I have placed an Inkscape document in a directory ~Escritorio/New Folder
. The file is called dibujo.svg
. If I double click it I get two errors:
Google Translate has "Error when loading the requested file" as the translation of "error al carger el archivo pedido" from Spanish.
However if I open a terminal in that place and write inkscape dibujo.svg
everything works fine.
If I make "right click --> open with" and select a program other than Inkscape (say a text editor or an image viewer) there is no strange behavior.
I have tried with two file managers, Thunar and PCManFM, and am experiencing similar problems with both.
Yesterday the "software update app" suggested me a list of updates and I decided to apply them. Today I start my computer to find that a program I use every day is not working properly. The program is Lyx. Is there any way to revert this updates? I have tried with Synaptic but it gives me no options to "force version".
In this link it can be found a screencast illustrating the problems.
Added image from the screencast:
I use Xubuntu and am very happy with XFCE. I use it in a netbook and saving screen space is vital for me. So I want to move the menus to a bar like it was in Unity. Some months ago I had followed the tutorial in this link and it had worked fine in Xubuntu 16.04. Now I have installed Xubuntu 18.04 and am getting this error:
~$ sudo add-apt-repository ppa:webupd8team/mate
The packages in this PPA require MATE 1.8 or newer. For Ubuntu 14.04, it depends on the following PPA:
https://launchpad.net/~ubuntu-mate-dev/+archive/ubuntu/trusty-mate
Currently, this PPA only provides TopMenu (global menu) from Git for MATE 1.8+ and Xfce. More information:
- MATE: http://www.webupd8.org/2014/12/get-global-menu-in-mate-18-with-topmenu.html
- Xfce: http://www.webupd8.org/2015/02/use-global-menu-in-xubuntu-or-linux.html
Más información: https://launchpad.net/~webupd8team/+archive/ubuntu/mate
Pulse [ENTRAR] para continuar o Ctrl+C para cancelar la adición.
Obj:1 http://ar.archive.ubuntu.com/ubuntu bionic InRelease
Des:2 http://security.ubuntu.com/ubuntu bionic-security InRelease [83,2 kB]
Obj:3 http://ar.archive.ubuntu.com/ubuntu bionic-updates InRelease
Obj:4 http://ppa.launchpad.net/lyx-devel/release/ubuntu bionic InRelease
Obj:5 http://ppa.launchpad.net/snwh/ppa/ubuntu bionic InRelease
Obj:6 http://ar.archive.ubuntu.com/ubuntu bionic-backports InRelease
Ign:7 http://ppa.launchpad.net/webupd8team/mate/ubuntu bionic InRelease
Err:8 http://ppa.launchpad.net/webupd8team/mate/ubuntu bionic Release
404 Not Found [IP: 91.189.95.83 80]
Leyendo lista de paquetes... Hecho
E: El repositorio «http://ppa.launchpad.net/webupd8team/mate/ubuntu bionic Release» no tiene un fichero de Publicación.
N: No se puede actualizar de un repositorio como este de forma segura y por tanto está deshabilitado por omisión.
N: Vea la página de manual apt-secure(8) para los detalles sobre la creación de repositorios y la configuración de usuarios.
~$ sudo apt install xfce4-vala-appmenu-plugin unity-gtk3-module unity-gtk2-module appmenu-qt appmenu-qt5
Leyendo lista de paquetes... Hecho
Creando árbol de dependencias
Leyendo la información de estado... Hecho
El paquete appmenu-qt5 no está disponible, pero algún otro paquete hace referencia
a él. Esto puede significar que el paquete falta, está obsoleto o sólo se
encuentra disponible desde alguna otra fuente
E: No se ha podido localizar el paquete xfce4-vala-appmenu-plugin
E: El paquete «appmenu-qt5» no tiene un candidato para la instalación
I don't want to install MATE, I want to keep XFCE but with the global menu bar.
I use Xubuntu 16.04 and when I connect my Samsung Galaxy S5 nothing happens, neither in the phone nor in the PC. The phone charges, yes, but nothing else. It does not appear any message or option about what to do with the USB connection (only charge, MTP, etc). I have installed gMTP and nothing.
Using the same phone, the same PC, the same cable, the same USB port but booting with Windows 8 everything works ok. The phone asks what to do (only charge, MTP, etc) and the PC can access normally to the content. This makes me believe that the problem is with Ubuntu.
EDIT 1:
I have noticed that when I plug the phone into the PC (Ubuntu) the "what do you want to do with the USB connection?" notification in Android appears and after about 2 seconds it automatically disappears. So it seems as is the phone does connect for a short time before it is unmounted automatically. I have tried "watch -n 0,1 lsblk" and also "watch -n 0,1 lsusb" to see if something appears during this short time period when it is plugged but nothing.