I need to convert xlsx into csv file using shell script. I am using RHEL 7.2 linux version. Is there any option to convert xlsx into csv file? please suggest me. Thanks in advance
sudo pip install xlsx2csv
You can refer to
https://github.com/dilshod/xlsx2csv
I've had good experiences with a python converter called (what a surprise!) xlsx2csv.
There shouldn't be any problem installing it on RHEL 7.2.
Related
I have a simple python program which will do process an xls file and append it. The problem here is i cannot install packages eg. XLWINGS on prod server (due to compliance issues). However I can install this package (XLWINGS) on my local system. I am thinking of writing a python program locally and create an UNIX executable file of it. My intention is that i will take this executable file/package to the UNIX server and run it without having to install the XLWINGS. Is this possible? If yes could you please help me with an example, I am new to Python. Thanks in advance.
I wrote a python script that uses an external .exe file for running commands, and I want to pack both .exe and .py files into one .exe file using pyinstaller
At the moment I don't know if pyinstaller supports this? I will be happy to hear if there are alternative ways.
Thanks in advance
I found how to do it, using the following command:
pyinstaller -y --add-data "C:/Users/Username/Projects/python3/foldername/someExeFile.exe";"." "C:/Users/Username/Projects/python3/foldername/somePyFile.py"
I'm new to Python, but I have set up an python script for searching some specific Values in 2 different excel sheets printing out matches (in excel).
Problem is, that our work machines are heavily locked down and without admin privileges, we can't really install anything (we can download though). Is there any version of Python that is Windows 7 compatible that will run standalone without requiring any sort of installer?
I have tried pyInstaller, but the problem is that in my script we need PANDAS.
And there is no possibility to pip install pandas to our local machines. All is blocked. ("pip install pandas" is not possible. I did the code with Anaconda)
So my question is: how can I set up a file for my coworkers, who have no permission to download pandas?
Can I set up an exe file (all use windows 7/10) in my private computer where pandas is already installed and forward it to the workers?
It should be very easy for them to use--> double click for executing the python script
Thanks in advance for any advice.
You can also use pyinstaller which personally I find the easiest to use. It can bundle executables for both Linux and Windows, but it must be run on that architecture that you wish to have executable for, i.e. if you want to have Linux executable the pyinstaller command with your code must be run on Linux OS of some kind.
More here: https://www.pyinstaller.org/
This is old so you may already have found a solution but this might help others.
Python by default is an interpreted language. This means that compiling it into an .exe file is impossible.
However, using some modules it is indeed possible to convert a .py script into a windows executable.
You can try py2exe.
py2exe is a Python Distutils extension which converts Python scripts
into executable Windows programs, able to run without requiring a
Python installation.
They have a tutorial here.
I wanted to use the code:
import geodict_lib
locations = geodict_lib.find_locations_in_text(text)
But there seems to be no installer for geodict_lib. How do I install this is Anaconda 3.0 Python 3?
I know this is a year on, but perhaps I could help others who stumble on this. You'll need to place the files in the directory for modules that your installation of Python is monitoring.
First, download the .zip file from GitHub here.
Once you've done that, you can run the following at the command line or terminal:
conda list
This will provide the path to all installed packages in your installation of Python. Move the geodict.zip file you downloaded to that location. You might want to run which python as well (see here) since you may have a few different installations to check for.
Now when you run python import geodict in Python it should run without trouble!
I am trying to convert a .docx file to PDF using LibreOffice 4.3 on RHEL 6.5 (corporate server).
For some reason, there is no output at all:
../program/soffice --headless --convert-to pdf --outdir . lock.docx
I am running the command as root, so I don't see any problems with permissions.
This is similar to this question, but I cannot convert ANY MS Office documents.
I installed LO on an EC2 instance, and it converts .docx to PDF just fine.
What areas could be causing the issue? Any suggestions on what I should be looking at?
Thanks!
Turns out I needed a whole set of dependent RPMs installed first, culminating in libGLU. I've included my additional RPM dependency tree if it will be of use:
libIDL-0.8.13-2.1.el6.x86_64.rpm
ORBit2-2.14.17-5.el6.x86_64.rpm
sgml-common-0.6.3-33.el6.noarch.rpm
GConf2-2.28.0-6.el6.x86_64.rpm
avahi-glib-0.6.25-15.el6.x86_64.rpm
gnome-vfs2-2.24.2-6.el6.x86_64.rpm
libXxf86vm-1.1.2-2.el6.x86_64.rpm
mesa-dri-filesystem-9.2-0.5.el6_5.2.x86_64.rpm
mesa-private-llvm-3.3-0.3.rc3.el6.x86_64.rpm
mesa-dri1-drivers-7.11-8.el6.x86_64.rpm (--nodeps)
mesa-dri-drivers-9.2-0.5.el6_5.2.x86_64.rpm
mesa-libGL-9.2-0.5.el6_5.2.x86_64.rpm
mesa-libGLU-9.2-0.5.el6_5.2.x86_64.rpm