Where is the linux mint panel applets config file? - configuration-files

OS: Linux Mint 18.3 Sylvia
DE: xfce4
I have to set up several PCs and want to write a script which configures the launcher-applets in the panel. So the script would contain in the end something like:
sudo cp ./my-predefined-config-file.type /path/to/location/
Edit:
I figured out that the launchers are saved at the following file-path:
/home/user/.config/xfce4/panel/
However copying a launcher, from another system, into this directory does not make them appear in the panel:
~$ cp -r ~/Desktop/launcher-1/ ~/.config/xfce4/panel/
So there must be still somewhere a config-file which i have to edit in order to make the launcher appear in the panel.
PS:
After changing something I am of course always reloading xfce in order to see the changes:
~$ xfce4-panel -r && xfwm4 --replace

For the record, on my Linux Mint 19.2 with Cinnamon install (not: xfce4 as in the question), the panel launcher config file is at
~/.cinnamon/configs/panel-launchers#cinnamon.org/3.json

Related

PhpStorm in Ubuntu can't detect pd_dump executable on PostgreSQL Export

My environment:
Ubuntu 20.04.3 LTS on Windows 10
-> https://www.microsoft.com/store/productId/9NBLGGH4MSV6
PhpStorm 2022.1 Build #PS-221.5080.224, built on April 13, 2022
My Problem:
I'm trying to export a PostgreSQL database inside the Database tab of PhpStorm.
To execute the export I right click the database in the list and click on the "Export with 'pg_dump'" option. This opens the Export window with all the options and command preview:
Inside of the window I get the error message "Path to executable is wrong" even tho the pg_dump file exists at the given path /usr/bin/pg_dump. This stops me from executing the export.
I have tried to manually install pg_dump in another directory and select it in the PhpStorm Export window, but it still won't detect the executable. The executable itself works fine.
The solution to this problem was to do a sudo apt-get install postgresql-client.
Apparently there is a general problem with the pg_dump executable of the "postgresql-client-common" package:
https://askubuntu.com/questions/501091/command-pg-dump-not-found
After installing the postgresql-client package, everything works fine in PhpStorm as well.
The code is pretty simple there: IDE checks that file exists and is executable, then run /path/to/pg_dump --version command and parse output looking for some keywords. Unfortunately there are no logs which can show exact reason, but I guess the issue that IDE can't get access to the file. Most likely due to WSL. The workaround is to install IDE and unpack PG binaries on Windows, then configure port forwarding to make PG server accessible from host OS.

How can I ensure HGFS in CentOS via Vagrant?

I am using Vagrant (1.7.4) with the VMware Fusion provider.
I have created a new VM from the centos/7 box, and configured shared folders in my Vagrantfile.
On startup, I get the message
HGFS was never found on the running virtual machine. This must be
installed either through VMware tools or Open VM Tools. HGFS is
required for shared folders to work properly. Please install either
the VMware tools or Open VM Tools and try again.
after a while, and the system starts up, but without the mounted shared volume.
I have tried installing Open VM tools, with a
sudo yum -y install open-vm-tools
in my Vagrant provisioner inline shell script
config.vm.provision "shell", inline: <<-SHELL
sudo yum -y update
sudo yum -y install open-vm-tools
SHELL
However, I still get the message at startup, and I do not see the mounted share.
I have an almost identical Ubuntu box (precise/64) that seems to work just fine.
I looked up the box https://atlas.hashicorp.com/centos/boxes/7 and from the release notes they clearly mention that virtual box guest are not installed
The VirtualBox Guest Additions are not preinstalled; if you need them for shared folders, please install the vagrant-vbguest plugin. We recommend using NFS instead of VirtualBox shared folders if possible.
I think what they should mention is that they did not install the VMWare tools neither so default sharing folder with VMWare does not work.
How to install the VMWare tools for the VM
Make sure to mount a cd
Open VMWare Fusion and make sure the VM is down - open the VM settings, select the hard drive and add a device, select the CDRom.
boot the VM from the VM menu select Install VMWare Tools
Installing VMWare Tools
login to the VM (either from VMWare or open an ssh session with vagrant ssh)
Install pre-requisites and update kernel (at least I had to run to successfully install the VMWare tools on VMWare fusion 8.0 - see here)
sudo yum install perl gcc gcc-c++ make binutils
sudo yum update kernel
reboot and run the following again
sudo yum install kernel-headers kernel-PAE-devel
mount the VMWare tools
this is found from the VMWare doc - Make sure to run the below commands with root or add sudo
To create a mount point, run:
mkdir /mnt/cdrom
To mount the CDROM, run:
mount /dev/cdrom /mnt/cdrom
To copy the Compiler gzip tar file to a temporary local directory, run:
cp /mnt/cdrom/VMwareTools-<version>.tar.gz /tmp/
Where version is the VMware Tools package version. To determine the version of VMware tools, run:
ls /mnt/cdrom
You see output similar to:
VMwareTools-5.0.0-12124.tar.gz
To change to the tmp directory and extract the contents of the tar file into a new directory called vmware-tools-distrib, run:
cd /tmp
tar -zxvf VMwareTools-version.tar.gz
To change directory to vmware-tools-distrib and run the vmware-install.pl PERL script to install VMware Tools, run:
cd vmware-tools-distrib
./vmware-install.pl
After all this, the tools were installed and shared folder is working correctly.
as a side note I can say that its much easier building a box with packer and install the tools directly from install. There are plenty of packer templates available on github for all versions of centos.

Using a sort of portable JDK on centOs

This is the first time that I use linux in my life, I'm a little bit strugling.
Permissions, user, folder structure, it's a lot to take in.
Everything I did, I did with the ATH user which is a regular non sudoer user.
I got Centos minimal and put it in a VM
then I extracted the linux tar.gz jdk in /home/ath/monitoring/jdk1.8.0_70_linux64
And I added this to a sh script, this sh script call other sh script
I want them to only use this jdk
below #!/bin/sh I added
export JAVA_HOME=/home/ath/monitoring/jdk1.8.0_70_linux64
However when I launch the script I get :
Which : no java in (/usr/local/bin:/usr/bin:usr/local/sbin:/usr/sbin:/home/ath.local/bin:/home/ath/bin)
Could not find any executable java binary. Please install java in your PATH or set JAVA_HOME
What am I doing wrong?
Thanks
ps : I used (logged as root) chmod +x /home/ath/monitoring/elasticsearch/bin/elasticsearch/bin/elasticsearch.sh
on the sh script otherwhise it would not run
So I also had to add this line because the script was looking into PATH :
export JAVA_HOME PATH=$JAVA_HOME/bin:$PATH
And I had to render all the file in jdk/bin executable running this inside
chmod a+x *
I don't get it tho, each time I'm getting a software I have to manually go and chmod every file that need it? quite bothersome.

How do I install the Matlab MCR in Ubuntu 14.04 without "killing" Unity?

Background: I have created an Ubuntu VirtualBox from LAPP stack and added the Ubuntu desktop (Unity: sudo apt-get install ubuntu-desktop). Now I am attempting to install the MCR without loosing Unity.
Download MCR zip and extract to MCR_SOURCE
Go to my folder that contains the files: cd /media/sf_shared/MCR_ SOURCE
Change installer_input.txt file:
destinationFolder=/opt/MCR
agreeToLicense=yes
outputFile=/opt/install.log
mode=silent
product.MATLAB
product.MATLAB_Builder_JA
# Note: To find out the required toolboxes >> start Matlab >> run your code and find out which toolboxes were used with: license('inuse')
Install MCR: sudo ./install -inputFile /media/sf_shared/MCR_SOURCE/installer_input.txt >> success
Restart Ubuntu >> test whether Ubuntu’s Unity still exists >> everything is fine
Attention the next step will “ kill ” your Ubuntu desktop configuration!!! (i.e. copy your hardisk, anything you must do to recover quickly) – now configure: sudo gedit /etc/environment
LD_LIBRARY_PATH="/opt/MCR/v84/runtime/glnxa64:/opt/MCR/v84/bin/glnxa64:/opt/MCR/v84/sys/os/glnxa64:${LD_LIBRARY_PATH}"
XAPPLRESDIR="/opt/MCR/v84/X11/app-defaults"
# Note: X11/app-defaults folder has not been created during installation
Restart Ubuntu >> Unity is gone, recovery attempts such as deleting the above lines do not recover Unity; reinstalling the Ubuntu desktop does not help either.
I have tried an alternative route with exporting the variables, which also "kills" Unity. By the way this affects all users.
Any ideas?
It is not necessary to register these environment variables in /etc/environment, which means that the Unity sidebar will not be affected.
Instead register the environment variables temporarily either as local user or via sudo -i:
export LD_LIBRARY_PATH="/opt/MCR/v84/runtime/glnxa64:/opt/MCR/v84/bin/glnxa64:/opt/MCR/v84/sys/os/glnxa64:${LD_LIBRARY_PATH}"
export XAPPLRESDIR="/opt/MCR/v84/X11/app-defaults"
Now it is possible to run Matlab Apps without "killing" Ubuntu's desktop. For instance to run the Java compiled makesqr.m file.
java -classpath "/opt/MCR/v84/toolbox/javabuilder/jar/javabuilder.jar:/media/sf_shared/for_testing/makesqr.jar" makesqr.Class1 5
The Java package makesqr was created using Matlab's JavaBuilder tutorial. This was done on my Windows 7 machine, which runs Matlab R2014b.
Please ensure that the owner and permissions of the /opt/MCR and /media/sf_shared/for_testing folders are set correctly (see here for details).

How do I make launcher of Maple12 on my Desktop. Linux Mint

I have recently buy and installed Maple 12 on Linux Mint. It has installed on root directory.
/root/maple12, the problem is that I don't know how to setup a launcher from the desktop.
What are all the steps do I need to follow?
Create an empty file on your Desktop named "Mapple12.desktop" and put the following content there:
[Desktop Entry]
Name=Mapple12
Icon=path_to_icon_file
Exec=path_to_execuatble_file
Type=Application
save and close the file.
Finally modify permission on your mapple directory to run it from desktop:
sudo chmod -R 777 path_to_mapple_directory