title: Howto start gvim with a maximized window from a bash-script in gnome
body: <p>I want to write a bash-script that starts a gvim-session directly in a maximized window.</p>
  
  <p>That is my bash-script:</p>
  
  <pre><code>#!/bin/bash - 
  set -o nounset
  
  cd /home/alexthebird/vim-stuff; # directory of the gvim-session file
  gvim -S bootmap;                # start gvim from the sessionfile 'bootmap'
  </code></pre>
  
  <p>Do you have any ideas how to accomplish this with a bashscript? Gvim should only be maximized when it is started over this script. Any other ideas how to accomplish this are welcome, of course.</p>
  
  <p>I use Ubuntu 11.04 with gnome.</p>
  
  <p>Thank you for taking the time to read my message.</p>
  
  <p>AlexTheBird</p>
  
  <p><strong>This script works:</strong></p>
  
  <pre><code>#!/bin/bash - 
  set -o nounset
  # directory of the gvim-session file
  cd /home/alexthebird/vim-stuff;
  # -f because of a ubuntu global-menu bug
  # -S starts from session-file named 'bootmap'
  # -geom solved the problem. see post of Lstor
  gvim -geom '200x50+0+0' -f -S bootmap; # start gvim from the sessionfile 'bootmap';
  </code></pre>
  
  <p>Thank you all for your time.</p>
  
  <p><strong>EDIT :</strong> I just found out that the above solution <strong>only works for the unity-2d (non 3D accelerated) desktop</strong>. Which is fine for me. It does not work with the default Ubuntu-desktop which uses the 3D accelerated version of Unity.</p>