Make Executable (Skip Executable Bit)
Nautilus Scripts
Description:

I hate this, I downloaded an untrusted application and want to execute it and THERE IT IS. This damn Executable Window.

Well I am to lazy to open the SHell and change its chmod.
Or even rightclick and change those Settings is to hard ;)

So I made this little Script. It allows you to directly change the chmod of the given File.

Note: This doesnt work on Remote Folders or Windows Partitions!

Just Rightclick of the given File and `Make Executable ! :)`


Installation is simple.
Just run the Program without any arguments.
The script prompts for the Installation.
Type: `y` if you hadn`t change your Home-Directory.

6 years ago

brucelee

It's a good ideea if you don't want to deactivate that check.
Here's a small script which I use and makes the wine launcher skip the executable bit check:


#!/bin/bash
if [ "$(id -u)" != "0" ]; then printf "\n * You must run this script as root.\n\n"; exit 0; fi
echo '[Desktop Entry]
Type=Application
Name=Wine Windows Program Loader
Exec=wine start /unix %f
MimeType=application/x-ms-dos-executable;application/x-msi;application/x-win-lnk;application/x-ms-shortcut
Icon=wine
NoDisplay=true
Icon=wine
StartupNotify=true' > /tmp/wine.desktop
sudo cp --remove-destination /tmp/wine.desktop /usr/share/applications/wine.desktop
sudo rm -f /tmp/wine.desktop

Just put this in a file and run it as root. It should fix it. No need to call a script for each .exe you want to run.

Report

6 years ago

inameiname

Nice idea. Unfortunately, I couldn't get it to work. However, using a Nautilus-Action that I've had for a while that does this very thing I tweaked your script around a little to make it work. It works for multiple files now:

!/bin/bash
# Change the Install_Path.

INSTALL_PATH="/home/$USER/.gnome2/nautilus-scripts"

# Set IFS so that it won't consider spaces as entry separators. Without this, spaces in file/folder names can make the loop go wacky.
IFS=$'\n'

# See if the Nautilus environment variable is empty
if [ -z $NAUTILUS_SCRIPT_SELECTED_FILE_PATHS ]; then
# If it's blank, set it equal to $1
NAUTILUS_SCRIPT_SELECTED_FILE_PATHS=$1
fi

# Loop through the list (from either Nautilus or the command line)
for ARCHIVE_FULLPATH in $NAUTILUS_SCRIPT_SELECTED_FILE_PATHS; do
NEWDIRNAME=${ARCHIVE_FULLPATH%.*}
FILENAME=${ARCHIVE_FULLPATH##*/}
NAME=${ARCHIVE_FULLPATH##*/.*}

if [ "$ARCHIVE_FULLPATH" ];then
gnome-terminal -x sudo chmod +x "$ARCHIVE_FULLPATH"
zenity --info --text="File "$ARCHIVE_FULLPATH" is now executable! :)"
else
# Install Script
echo "Installing Nautilus-Extension.."
echo "Install Script in: $INSTALL_PATH - Is that right? [y/n]"
read input
if [ "$input" == "y" ];then
mv "$0" "$INSTALL_PATH"
echo "Installation Successfully! :)"
else
echo ""
echo "Enter the /home/<name> NAME of your Homedir."
echo "Example: your home is /home/jjd - so type: jjd:"
read homedirname
sleep 1
echo "Installing Nautilus-Extension to /home/$homedirname/.gnome2/nautilus-scripts"
mv "$0" "/home/$homedirname/.gnome2/nautilus-scripts"
echo "Done! :)"
fi
fi
done

Report

Supporters

Recent Donations

Be the first to donate
Filename Version Description Filetype Packagetype License Downloads Date Filesize Install
Score 50%
50.00 Likes
50 Dislikes

0 Supporters for Make Executable (Skip Executable Bit):

Recent Donations:

Be the first to donate
show all
Details
version
0.0.1
updated Dec 21 2010
added Dec 21 2010
downloads
page views 292
support posixpascal
For The Product
Make Executable (Skip Executable Bit)
5 - 10 - 25 - 50 - 100 - 200 - 500