ONLYOFFICE and mime-types assosiasions - mime-types

I`m using Elementary Os Loki and wanted to use ONLYOFFICE.
I tried installing the last deb file from official site and tried to use the repo(no change). The problem is that when the package installs it doesn`t register itself to allow opening the file from filemanager or terminal(desktopeditors -f example.doc or smth).
I found whole dir in the official repo where I think all logic is handled.
(https://github.com/ONLYOFFICE/desktop-apps/tree/master/win-linux/package/linux/qt-installer/packages/onlyoffice/data)
I also tried to fix by changing file in /usr/share/applications - defaults.list and desktopeditors.desktop.
Please fix this or give a nice explaination if it a feature.
The only way to open a file is to use internal file chooser dialog or to drag&drop a file on the window.

It is a bug in onlyoffice-desktopeditors. We will fix it soon. You can set file associations: open context menu of the file, choose "open with" -> "other applications". Then find 'desktopeditors' in recommended applications, select this and press 'Set as default' button.
After this you will be able to open files from file manager in ONLYOFFICE.

Related

Cannot install appx through graphic installer

I'm facing a problem right now and I don't really know how to get more informations about it.
I've converted a desktop application through Microsoft's Desktop App Converter, made some manual modifications about the visual assets, and rebundled it through "makeappx.exe". Then I signed it.
Everything went fine. Except that when I double click the appx to check it, I have the following window:
Appx Error
Which roughly translates as "Couldn't open the appx or appxbundle file" and "Reason: Failure caused by an unknown reason".
This does not helps me a lot :/
However, if I try to install the package through a simple "Add-appxpackage MyPackage.appx", it works perfectly fine.
Could anyone help me find some leads on what's happening here? I've already checked the event viewer as explained here but I couldn't find anything unusual.
Thanks,
Skefrep
It seems the Microsoft team has taken notice of this problem and investigated this appropriately.
-Here is their solution-
The problem can be because when you convert an app with DesktopBridge the resources are signed with the manifest info and store that info in the .pri files you found in PackageFiles folder. Later, when you change something like the Publisher or the Name this signature doesn't match. To fix this you only need to recreate the .pri files.
rm *.pri. Remove the old .pri files.
cd C:\foo\PackageFiles\. Change current directory to the PackageFiles folder. This step is important for the next step.
makepri createconfig /cf priconfig.xml /dq en-US. Create a configuration file for the resources.
makepri new /pr "C:\foo\PackageFiles" /cf "C:\foo\PackageFiles\priconfig.xml". Generate the new *.pri files.
Then you can make the package as usual: MakeAppx, etc.
You can find more information about this problem in "Failed due to unknown reasons" error when you try to sideload a Desktop Bridge app - App Consult Team.

Trying to set up a deployment package for silent uninstall of Notepad++ and installation of a new version

All of the below on Windows 7 Machines and regarding Notepad++ installation / uninstallation:
Uninstaller
When I try to uninstall using the command
if exist "C:\Program Files (x86)\Notepad++\uninstall.exe" "C:\Program Files (x86)\Notepad++\uninstall.exe" /S
there are some files left in the Notepad++ file afterward. Notepad++'s uninstaller, when run manually, prompts halfway through the uninstall asking "Do you want to keep your custom settings" and I'm thinking that the command may be choosing to answer this "Yes" by default. I'm wondering if there's an easy way to have it choose "No" here instead. If not, I can probably just delete the folder.
Installer
I'm running the installation using the 32 bit default .exe file from Notepad++ in a deployment package compiled in Lansweeper. What I'm noticing is that presently, the package executed the CMD uninstall command, but stops short of installing the new version. For reference, I've been using an installed 7.3.2 and the installer for 7.3.3 to test, so that it should uninstall the 7.3.2 and install 7.3.3 by the end of the package.
I'm wondering if the fact that there are a number of options in the Notepad++ installer could be the culprit here. If it is better to install via command line or to include some sort of configuration file I'm fine with either option, just not especially well-versed in doing them.
Notepad++ Installer requests the following during installation:
Select a language - should choose English
Choose Components - want to be able to customize selection of localization / auto complete / themes / context menu / plugins / auto update according to our requirements
Choose Components - Don't use Appdata, Allow Plugins to be loaded from Appdata, and Create Shortcut on Desktop should all remain unchecked
Run Notepad ++ - should be unchecked (checked by default)
All the other components that I can see are straightforward Next / I Agree buttons.
I'm hoping someone may be able to make helpful suggestions here as I've not had any experience with configuring silent installs with specific parameters. Notepad++ doesn't seem to have its own MSI and I won't use a third party one so some sort of batch or configuration file or flagging options in cmd if possible are the preferable options.
Please let me know if there's any additional information I can provide that may be helpful.
Thank you in advance.
If you just need to update to the latest version. It is quite simple. Run the newest installer again and it will automatically update older versions.
See
Silent Install Notepad++
I'm using the command:
start /wait npp.7.2.Installer.x64.exe /S
Didn't show any interface during silent installation.
Notepad kicks a secondary process that doesn't finish until success is evaluated.
try:
"%ProgramFiles(x86)%\Notepad++\uninstall.exe" /S
timeout 5

touch .gitignore not creating file

I'm trying to set up a React dev environment, and one instruction I've been given is to enter my directory in Terminal and type this code:
touch .gitignore
The touch command works fine when I'm making a file with a name and extension (e.g. index.html) but since this appears to be only an extension, nothing is happening.
Apparently it's an important file regarding uploading to GitHub - can anyone help?
Update: I created x.gitignore, and then tried deleting the x, and it OSX throws up a dialog saying:
You can’t use a name that begins with a dot “.”, because these names are reserved for the system. Please choose another name.
You can see all of the visible files within a folder by typing
ls
into your terminal (assuming OSX from your comment). However, you will only see a list of the non-hidden files. You can see all files by typing
ls -a
Your .gitignore file basically tells git which folders and files to disregard when packaging everything up to be stored. For example, in ReactJS projects you are probably going to be using a lot of NPM packages and you wouldn't want to include them in your git repository. So, in your .gitignore file, you would include a line that says
node_modules
and then none of the files or folders within node_modules would be included when you push to Github (or Bitbucket or wherever).
If you are having trouble finding the .gitignore file, first run the ls -a and make sure that you see the file listed. After that, if you are having trouble seeing the file in your text editor, you may want to check the preferences in the text editor.
In Atom, you need to unselect "View VCS Ignored Paths" to see the "ignored" files.
type in terminal
npx touch .gitignore

How download exe files with ChromeDriver?

I try to download exe files via ChromeDriver. But I see the following message: "This type of files can harm your computer..."
How I can avoid this message?
I don't think that we can switch off those messages in Chrome.
But i have a workaround.
1) chrome://settings/ --> Downloads --> Select the "Ask where to save each file before downloading" check box. Then every time before downloading a file chrome will ask you where to save the file & the default location is "Downloads" folder.
2) Write an AutoIt script just to press ENTER (As the focus is already on the popup).
Send("{ENTER}")
3) Once you click on the Download link, Run the above AutoIt Script using below command:
Runtime.getRuntime().exec("Path of the AutoIt executable");
It's fine to download files. It will shows such error for .js, .exe, .dll, excel macro files etc.
Things need to remember is when you try to install the software with any installer when you double click the exe file it will show you publisher name. If publisher is unknown it may possible that exe file is altered.
Most of the trusted software publishers use Code Signing Certificate to validate their software package. This way software shows their company name as a publisher, and assure that the software is not altered.

vim cannot connect to cscope database

I have opensuse 11.4 installed. Vim is version 7. Now I normally use it to browse the linux kernel source. So I generated the cscope database inside a directory within my home folder i.e. /home/aijazbaig1/cscope_DB/ and I got 3 files viz. cscope.out, cscope.po.out and cscope.in.out besides the cscope.files file which contains a list of all the relevant files which I want to search.
Additionally I have added the following to my .bashrc:
CSCOPE_DB=/home/aijazbaig1/cscope_DB/cscope.out
export CSCOPE_DB
But when I do a :cscope show from within vim it says there are no connections. Can anyone please let me know what is going wrong.
Keen to hear from you,
This is mentioned in the comments above, but I want to make sure it's preserved in an answer.
The issue that came up for me was that vim didn't know where to look for the cscope database. When I added
cs add $CSCOPE_DB
to my .vimrc. Everything came out fine.
I figure since I've made the visit, I would try responding.
I was getting this error when searching using ctrl-space s (or any search for that matter):
E567: no cscope connections
I finally found the full solution at http://cscope.sourceforge.net/cscope_vim_tutorial.html, Step 11.
The idea is that you create a list of source files to be included in the view of cscope, generate the cscope.out in the same location, and update the export path accordingly:
find /my/project/dir -name '*.c' -o -name '*.h' > /foo/cscope.files
cscope -R -b (this may take a while depending on the size of your source)
export CSCOPE_DB=/foo/cscope.out (put this in your .bashrc/.zshrc/other-starting-script if you don't want to repeat this every time you log into the terminal)
You need to add a "cscope connection", like this in vim:
:cscope add $PATH_TO_CSCOPE.out
See :help cs for more examples.
Here's how I explore linux kernel source using cscope:
I use vim as my editor.
While standing inside the kernel source root directory, run cscope in interactive mode while recursively going through subdirectories during search for source files:
cscope -R
When run for the first time, it will generate the database file with the name: cscope.out inside the current directory. Any subsequent runs will use the already generated database.
Search for anything or any file and open it.
Set cscope tags in vim to make the :tag and CTRL-] commands search through cscope first and then ctags' tags:
:set cscopetag
Set cscope database inside current VIM session:
:cs add cscope.out
Now you can use CTRL-] and CTRL-t as you would do in ctags to navigate around! :)
I have the same issue on my PC. For now, to solve the issue:
On terminal execute: which is cscope
Open .vimrc file to edit: set csprg=/usr/bin/cscope
I ran into a similar problem with no cscope connections on ubuntu 18.04, then I discovered my .vimrc file does not load the CSCOPE_DB variable. Looked a little around and found a solution.
You can just copy this directly in to your .vimrc file.
Part of the code loads your cscope file from your directory. The keybinds are just a nice bonus.
Hope this helps.

Resources