Monday, 10 November 2014

Elementary OS Luna Configuration Script

Elementary OS 'Luna'  rocks!...... BUT, it does need some help out of the box.  Nothing crazy, mostly look & feel improvements, removing programs and adding others.  I'm in the middle of buying a new laptop, and am trying out lots of different installs.  To help save time (and sanity) I wrote a short script to configure Luna the way I want right after install.

Now, it's not perfect.... there may be a few hiccups but it basically turns this:

Pre config script
.
.
. . .into this:
Post config script!

I think it's a lot more polished look, so I'm sharing the script below to help my fellow elementary OS-ers.  

What it does

Uninstalls all these default applications:
  • Midori (default browser) 
  • Software Center (default software management)
  • Scratch (text editor) 
  • ModemManager (does anyone really need this?)
  • Empathy (chat aggregator)
  • Indicator-messages (empathy chat in the toolbar)
  • Maya (default calendar)
  • Geary  (mail app....because, really, nothing beats Gmail in the browser)
  • Shotwell (photos)
  • Totem (video player)
  • Noise (I was going to replace this with Clementine but turns out I like Noise better)
Installs these (better?) applications:
  • Google Chrome
  • Firefox
  • Zotero  (& Qnotero)
  • Dconf tools
  • Gedit (text editor)
  • Gnome Partition Manager
  •  VLC media player
  • Lots of unzip and file packaging utilities
  • Ubuntu Restricted Extras
  • Pinta (image editor... yeah, I like it better than the Gimp)
  • GPicView Image Viewer
  • Elementary Tweaks (this rocks!)
  • a bunch of Elementary Window, Icon & Plank themes
  • Super Wingpanel & Synapse search indicator
  • Skype
  • Libreoffice & dictionaries
  • QBitTorrent
  • Conky
Makes some settings & config changes:
  • Shortens window open/close animation time
  • Reduces window shadows but about 90%
  • Top-left hot corner shows all windows
  • Default "list" in pantheon-files (instead of icons) and default double-click (instead of single)
  • Change Plank icons (smaller) and apply HUD theme
  • Apply elFaenza icon set to everything
  • Configure Conky (a la custom elementary OS conky theme)
  • a few other gedit and terminal settings changes

Some cavetats

  • Some applications need 3rd party repositories.  These REPOSITORIES WILL BE ADDED TO YOUR APPROVED LIST
  • You might need to make some edits to your conky script to get it working properly
  • Super-Wingpanel and Conky might not work correctly until a reboot
  • Many settings can be modified and tweaked via Elementary Tweaks.  Access this from your Settings application menu.

Ok, ok, where's the script?

Download it here or copy the full text below:
#!/bin/bash        

### Written by anjp on 04-November-2014
### http://justplainobvious.blogspot.com
###  
### Download Elementary OS from here:
### http://sourceforge.net/projects/elementaryos/files/stable/
###
### Save this script as Luna_config.sh and run in Terminal "sudo sh Luna_config.sh"


###  Function list
RunWholeScript(){
    while true; do
        read -p "Are you sure? Run with NO USER INPUTS (y/n)???" yn
        case $yn in
            [Yy]* )
                    ### Remove the eOS Junk                  
                    read -p "First is removing eOS default apps.  Press ENTER key to continue..." pause
                    sudo apt-get autoremove --purge midori-granite software-center scratch-text-editor modemmanager empathy indicator-messages maya-calendar geary shotwell totem              
                    echo "Done removing eOS junk apps...\n"
                    ### Add all the new Repos
                    read -p "Next is adding new Repos.  Be patient.  Press ENTER key to continue..." pause
                    sudo add-apt-repository ppa:pinta-maintainers/pinta-stable
                    sudo apt-add-repository ppa:versable/elementary-update
                    sudo add-apt-repository ppa:smathot/cogscinl
                    sudo apt-add-repository "deb http://archive.canonical.com/ubuntu/ precise partner"
                    sudo add-apt-repository ppa:libreoffice/ppa
                    sudo add-apt-repository ppa:git-core/ppa
                    wget -q -O - https://dl-ssl.google.com/linux/linux_signing_key.pub | sudo apt-key add -
                    sudo sh -c 'echo "deb http://dl.google.com/linux/chrome/deb/ stable main" >> /etc/apt/sources.list.d/google-chrome.list'                  
                    wget https://raw.github.com/smathot/zotero_installer/master/zotero_installer.sh \    -O /tmp/zotero_installer.sh
                    chmod +x /tmp/zotero_installer.sh                  
                    echo "Done adding Repos...\n"
                    ### Update
                    read -p "Next is an apt-get update.  Press ENTER key to continue..." pause
                    sudo apt-get update
                    echo "Done with update\n"
                    ### Install new software                                      
                    read -p "Next is installing all new software.  Press ENTER key to continue..." pause                  
                    sudo apt-get install google-chrome-stable firefox dconf-tools gedit gedit-plugins gparted vlc unace unrar zip unzip xz-utils p7zip-full p7zip-rar sharutils rar uudeview mpack arj cabextract file-roller ubuntu-restricted-extras pinta gpicview elementary-desktop elementary-tweaks elementary-blue-theme elementary-champagne-theme elementary-colors-theme elementary-dark-theme elementary-harvey-theme elementary-lion-theme elementary-milk-theme elementary-plastico-theme elementary-whit-e-theme elementary-elfaenza-icons elementary-emod-icons elementary-enumix-utouch-icons elementary-nitrux-icons elementary-taprevival-icons elementary-plank-themes super-wingpanel indicator-synapse qnotero skype libreoffice libreoffice-style-human libreoffice-style-oxygen libreoffice-style-crystal libreoffice-style-sifr libreoffice-style-tango libreoffice-style-galaxy libreoffice-pdfimport hyphen-en-us mythes-en-us libreoffice-help-en-us qbittorrent git conky lm-sensors
                    sudo /tmp/zotero_installer.sh
                    sudo rm /tmp/zotero_installer.sh
                    echo "Done installing new software...\n"                                      
                    ### Gala Configs - Window Animations
                    read -p "Next is shortening Window Animations.  Press ENTER key to continue..." pause                                      
                    gsettings set org.pantheon.desktop.gala.animations close-duration 260
                    gsettings set org.pantheon.desktop.gala.animations menu-duration 120
                    gsettings set org.pantheon.desktop.gala.animations minimize-duration 160
                    gsettings set org.pantheon.desktop.gala.animations close-duration 300
                    gsettings set org.pantheon.desktop.gala.animations snap-duration 120
                    gsettings set org.pantheon.desktop.gala.animations close-duration 300
                    echo "Done shortening Window Animations...\n"
                    ### Gala Configs - Change to Windows Min/Max/Close
                    read -p "Next is changing window min/max/close buttons.  Press ENTER key to continue..." pause                                      
                    gsettings set org.pantheon.desktop.gala.appearance button-layout ":minimize,maximize,close"
                    echo "Done changing window buttons...\n"
                    ### Gala Configs - Change Hot Corner Top-Left
                    read -p "Next is changing top left hot corner.  Press ENTER key to continue..." pause                                      
                    gsettings set org.pantheon.desktop.gala.behavior hotcorner-topleft "window-overview"
                    echo "Done changing window buttons...\n"
                    ### Gala Configs - Decreasing Window Shadows
                    read -p "Next is decreasing window shadows .  Press ENTER key to continue..." pause                                      
                    gsettings set org.pantheon.desktop.gala.shadows dialog-focused "['2','-1','0','1','190']"
                    gsettings set org.pantheon.desktop.gala.shadows dialog-unfocused "['2','-1','0','1','130']"
                    gsettings set org.pantheon.desktop.gala.shadows menu "['2','-1','0','1','130']"
                    gsettings set org.pantheon.desktop.gala.shadows normal-focused "['3','-1','0','2','220']"
                    gsettings set org.pantheon.desktop.gala.shadows normal-unfocused "['2','-1','0','2','150']"
                    echo "Done decreasing window shadows...\n"
                    ### Gala Configs - Files LIST VIEW and DOUBLE CLICK
                    read -p "Next is changing Files List View and Double Click.  Press ENTER key to continue..." pause                                      
                    gsettings set org.pantheon.files.preferences default-viewmode "list"
                    gsettings set org.pantheon.files.preferences single-click false
                    echo "Done Gala Files configs ...\n"
                    ### Gedit Configs
                    read -p "Next are gedit formatting configs.  Press ENTER key to continue..." pause                                      
                    gsettings set org.gnome.gedit.preferences.editor auto-indent true
                    gsettings set org.gnome.gedit.preferences.editor display-line-numbers true
                    gsettings set org.gnome.gedit.preferences.editor display-right-margin true
                    gsettings set org.gnome.gedit.preferences.editor wrap-mode none                
                    echo "Done gedit configs...\n"
                    ### Terminal Configs
                    read -p "Next is changing terminal forget tabs upon reload.  Press ENTER key to continue..." pause                                      
                    gsettings set org.pantheon.terminal.settings remember-tabs false                  
                    echo "Done terminal configs...\n"
                    ### Super Wingpanel Configs
                    read -p "Next Super Wingpanel configs.  Press ENTER key to continue..." pause                                      
                    gsettings set org.pantheon.desktop.super-wingpanel enable-slim-mode true
                    gsettings set org.pantheon.desktop.super-wingpanel hide-mode "Intellihide"
                    gsettings set org.pantheon.desktop.super-wingpanel slim-panel-edge "Curved 3"
                    gsettings set org.pantheon.desktop.super-wingpanel slim-panel-separate-launcher true
                    gsettings set org.pantheon.desktop.super-wingpanel slim-panel-margin 64
                    gsettings set org.pantheon.cerbere monitored-processes "['super-wingpanel', 'plank', 'slingshot-launcher --silent']"
                    killall wingpanel & super-wingpanel &        
                    echo "Done super-wingpanel configs...\n"
                 
                    ### Plank
                    read -p "Next is configuring Plank.  Press ENTER key to continue..." pause
                    rm ~/.config/plank/dock1/settings
                    rm ~/.config/plank/dock1/launchers/*                                  
   echo "#This file auto-generated by Plank.
#2014-11-05T04:11:42+0000

[PlankDockPreferences]
#Whether to show only windows of the current workspace.
CurrentWorkspaceOnly=false
#The size of dock icons (in pixels).
IconSize=40
#If 0, the dock won't hide.  If 1, the dock intelligently hides.  If 2, the dock auto-hides. If 3, the dock elementary-hides.
HideMode=3
#Time (in ms) to wait before unhiding the dock.
UnhideDelay=0
#The monitor number for the dock. Use -1 to keep on the primary monitor.
Monitor=-1
#List of *.dockitem files on this dock. DO NOT MODIFY
DockItems=google-chrome-stable.dockitem;;firefox.dockitem;;zotero.desktop;;libreoffice-startcenter.dockitem;;pantheon-files;;switchboard.desktop;;pantheon-terminal.desktop;;gnome-screenshot.desktop
#The position for the dock on the monitor.
Position=3
#The dock's position offset from center (in percent).
Offset=0
#The name of the dock's theme to use.
Theme=HUD
#The alignment for the dock on the monitor's edge.
Alignment=3
#The alignment of the items in this dock.
ItemsAlignment=3" > ~/.config/plank/dock1/settings


echo "[PlankItemsDockItemPreferences]
Launcher=file:///usr/share/applications/google-chrome-stable.desktop" > ~/.config/plank/dock1/launchers/google-chrome-stable.dockitem

echo "[PlankItemsDockItemPreferences]
Launcher=file:///usr/share/applications/firefox.desktop" > ~/.config/plank/dock1/launchers/firefox.dockitem

echo "[PlankItemsDockItemPreferences]
Launcher=file:///usr/share/applications/zotero.desktop" > ~/.config/plank/dock1/launchers/zotero.dockitem

echo "[PlankItemsDockItemPreferences]
Launcher=file:///usr/share/applications/libreoffice-startcenter.desktop" > ~/.config/plank/dock1/launchers/libreoffice-startcenter.dockitem

echo "[PlankItemsDockItemPreferences]
Launcher=file:///usr/share/applications/pantheon-files.desktop" > ~/.config/plank/dock1/launchers/pantheon-files.dockitem

echo "[PlankItemsDockItemPreferences]
Launcher=file:///usr/share/applications/switchboard.desktop" > ~/.config/plank/dock1/launchers/switchboard.dockitem

echo "[PlankItemsDockItemPreferences]
Launcher=file:///usr/share/applications/pantheon-terminal.desktop" > ~/.config/plank/dock1/launchers/pantheon-terminal.dockitem

echo "[PlankItemsDockItemPreferences]
Launcher=file:///usr/share/applications/gnome-screenshot.desktop" > ~/.config/plank/dock1/launchers/gnome-screenshot.dockitem
                    echo "Done Plank configs...\n"
                 
                    ### Conky
                    read -p "Next is configuring Conky.  Press ENTER key to continue..." pause                                      
                    wget http://anjp.comlu.com/scripts/.conkyrc
                    mv  ~/Downloads/.conkyrc ~/
                    wget http://anjp.comlu.com/fonts/Dotmatrx.ttf
                    wget http://anjp.comlu.com/fonts/PIZZADUDEBULLETS.ttf
                    wget http://anjp.comlu.com/fonts/STYLBCC_.TTF
                    wget http://anjp.comlu.com/fonts/openlogos.ttf
                    wget http://anjp.comlu.com/fonts/weather.ttf
                    mkdir ~/.fonts/
                    mv ~/Downloads/Dotmatrx.ttf ~/.fonts/
                    mv ~/Downloads/PIZZADUDEBULLETS.ttf ~/.fonts/
                    mv ~/Downloads/STYLBCC_.TTF ~/.fonts/
                    mv ~/Downloads/openlogos.ttf ~/.fonts/
                    mv ~/Downloads/weather.ttf ~/.fonts/
                    conky &
                    echo "Done ...\n"
                    read -p "Next is telling Conky to autostart.  Press ENTER key to continue..." pause                                      
                    mkdir ~/.config/autostart
echo > "[Desktop Entry]
Type=Application
Exec=conky -p 5
Hidden=false
NoDisplay=false
X-GNOME-Autostart-enabled=true
Name[en_CA]=Conky Launcher
Name=Conky
Comment[en_CA]=Conky!
Comment=Conky!" > ~/.config/autostart/Conky
                    echo "Done ...\n"
                 

                    # Change start menu to open with ONLY the Super key, instead of Super + Space
                    # gsettings set org.gnome.desktop.wm.keybindings panel-main-menu "['Super_L','F2']"
                    ### next line to change back ###
                    # gsettings set org.gnome.desktop.wm.keybindings panel-main-menu "['space', 'F2']"

                 
                    #Cleanup
                    sudo apt-get update
                    sudo apt-get upgrade
                    sudo apt-get autoremove
                    sudo apt-get autoclean
                    #All done
                    echo "\nNO USER INPUT script complete!\n"                  
                    read -p "Press ENTER key to exit..." pause            
                    exit;;
            [Nn]* ) break;;
            * ) echo "Please answer yes or no.";;
        esac
    done
}



echo "\n******************************************************"
echo "***********  eOS Luna configuration script  **********"
echo "******************************************************\n"
echo "This script will remove most of the eOS default applications and install more commonly used ones\n"
echo "See 'Luna_config.sh' for more info"
echo "Press CTRL + C at any time to exit...\n"
read -p "Press ENTER key to start..." pause


#### Option to just do everything without step-by-step
while true; do
    read -p "Do you just want to run the entire script WITH NO USER INPUTS (y/n)?" yn
    case $yn in
        [Yy]* )
                RunWholeScript
                break;;
        [Nn]* ) break;;
        * ) echo "Please answer yes or no.";;
    esac
done

### Starting user-input script
echo "\nStarting script with user input...\n"
echo "\n  Sorry, I got lazy and decided only to write the NO USER INPUT part!"
read -p "Press ENTER key to exit..." pause

Now just run the script in a terminal and follow the prompts:
sudo sh Luna_config.sh

I'm sure there will be some hiccups... post questions below and let me know what you did with all your time savings!


8 comments:

EruGaba said...

Hi there. I'd like to configure your script since there are default stuff i don't want to get rid of. and ignore installation of most new things since i've already installed them on my elementary. I'm not sure how to do it properly without messing something up. Would you lighten me up on how to do it? thanks in advance.

yanmaneee said...

yeezy boost 500
supreme clothing
adidas tubular shadow
nike air max
curry 6 shoes
jordan shoes
nike shoes
hermes belts for men
ferragamo belt
converse outlet

yanmaneee said...

supreme shirt
irving shoes
kyrie irving shoes
kd 13
nike off white
supreme new york
cheap jordans
kyrie 3
moncler outlet
kyrie irving shoes

Angel charls said...

Due to the threats of potential hackers and data thieves, Google is now more concerned about the security of android users than ever before. To protect its users, Google has added the Factory reset protection (FRP) feature. Google Account Manager APK Download 2021 Latest Version. This app can be extremely helpful in case you can’t remember the Google login credential and need to reset the android device immediately. All you have to do is install the Google Account Manager APK and you no longer need to bother about the FRP. In case the application is not working proper and ou want instant support from technicians then call at Google Telefoonnummer. who have proper knowldege and they will provide you a best solution as per your issue.

jackaljacintha said...

Woorxinos Casino: Review - WoorCasinos.info
Wagering 실시간바카라사이트 requirements · Games offered · Deposit bonuses · Deposit/withdrawal method · Games available 플레이포커 · 서산 휴게텔 Cashback 업소 추천 · Security and bet insurance policy for Woorxinos casinos.

Anonymous said...

golden goose shoes
off white outlet
jordan shoes
jordan 6
supreme clothing
supreme hoodie
100% real jordans for cheap
kd shoes
off white hoodie
off white hoodie outlet

meeteyez said...

q7e05m6x72 r0n02b8e40 z6y06r5o97 y2j47s1k32 y2a98x7k27 p4i97y3i72

Anonymous said...

bape clothing outlet
bape
supreme clothing
jordan outlet
kyrie 9
golden goose sneakers
curry shoes
golden goose outlet
golden goose official
ggdb outlet

  © Blogger template 'Isolation' by Ourblogtemplates.com 2008

Back to TOP