Actualizações de Lopo Lencastre de Almeida Mostrar/esconder comentários | Atalhos de teclado

  • Lopo Lencastre de Almeida May 1, 2014, às 15:07 Permalink
    Etiquetas: Advanced Packaging Tool, ElementaryOS, , , , Operating Systems, SourceForge   

    Building elementaryOS unstable images (0.3 isis) 

    1. install bzr: sudo apt-get install bzr
    2. copy eOS code branch: bzr branch lp:elementaryos
    3. cd to the dir: cd elementaryos
    4. Edit the config to suite your needs: cd etc && nano config
    5. You can specify the architecture to amd64 or i386, also tweak some things like base or version number (you should leave those as is).
    6. Add elementary daily ppa: sudo add-apt-repository ppa:elementary-os/daily && sudo apt-get update
    7. Go back to the main elementaryos folder and execute ./  it will tell you about required packages. Install them and run it again.
    8. When done builds will be in the builds folder.

    This project is putting up builds on sourceforge also if you don’t want to do it yourself >

    I would try it on a VM because this is pre-alpha software. Also you should report bugs to help development at

    note: Reposted from the defunct Tux Fiction blog.

  • Lopo Lencastre de Almeida April 25, 2014, às 14:01 Permalink
    Etiquetas: Font, , Operating system   

    New fonts not showing in Linux 

    If you install a new font in linux, you need to rebuild the fonts cache:

    sudo fc-cache -f -v

  • Lopo Lencastre de Almeida April 13, 2014, às 18:22 Permalink
    Etiquetas: Display resolution, , , , modeline, RandR, , , XFree86 Modeline, Xorg.conf   

    Add new screen resolution in X.Org 

    Linux does not have as much options for display resolutions as in Microsoft Windows. A 22″ Monitor in linux will have 1920×1080, 1440×900, 1280×960, 1024×768 resolutions. Some users may need resolution like 1600×900, 1366×768 for some purposes. These resolutions can be added manually in Linux.

    Basic steps for adding 1600×900 resolution are explained as under which can be modified for any other screen resolution by changing values 1600×900 with your required one.

    1. First step is to create modeline. This is done to get appropriate values of hsync, vsync and other parameters which are required to display a resolution properly in the backend. To add resolution of 1600×900, open terminal and type:

      cvt 1600 900

      This will create modeline for resolution of 1600×900 which will look something like this:

      # 1600x900 59.95 Hz (CVT 1.44M9) hsync: 55.99 kHz; pclk: 118.25 MHz
      Modeline "1600x900_60.00" 118.25 1600 1696 1856 2112 900 903 908 934 -hsync +vsync

      These numbers may vary according to your monitor.

    2. To add this resolution to monitor settings, type the following highlighted commands one by one:

      xrandr --newmode "1600x900_60.00" 118.25 1600 1696 1856 2112 900 903 908 934 -hsync +vsync

      Note: values after xrandr –newmode to be pasted from second line of generated values with cvt command from your own computer, don’t copy from here. In other words, after writing xrandr –newmode in terminal, copy the output of cvt command from its second line excluding word Modeline upto its end and paste it after xrandr –addmode.

      xrandr --addmode VGA1 "1600x900_60.00"

      After these steps, resolution of 1600×900 will appear under the list of various resolutions available in display settings. This will remain listed for one session only. When computer is restarted, this will disappear. To make it appear permanently, we need to configure xorg.conf file and make this entry manually.

    3. In Mint, xorg.conf is not present by default and has to be created. This can be created only when X server is not working ie. in console mode otherwise system will give error. Type these highlighted commands one by one in console mode:

      Ctrl+Alt+F1 (switch to console mode)
      Login by typing user name and password
      sudo service lightdm stop (For Mint 12 Lisa users) or sudo service mdm stop (For Mint 13 Maya and above users)
      sudo X -configure (generates new xorg.conf file)

      File with name will be created in Home folder. Although some error message will appear but file will be created. Just ignore that message.


      1. Use only one of the commands (from sudo service lightdm stop or sudo service mdm stop) according to your distro edition. These are used to kill X server.
      2. In Mint 13 Maya and above, after sudo service mdm stop, Ctrl+Alt+F1 has to be pressed again.

    4. To switch back to graphical mode, type:

      sudo start lightdm (Mint 12 Lisa users)
      sudo service mdm start (Mint 13 Maya and above users)

      If above commands fail to bring back graphical mode try to change it with Ctrl+Alt+F7 or Ctrl+Alt+F8. If that fails just restart your computer.

    5. Open Home folder. Rename this file from to xorg.conf. Open xorg.conf with text editor and make the following changes. Underline shows newly added lines:

      Modification #1 — Add Modeline in Monitor Section under each Identifier option. Example:

      Section "Monitor"
              Identifier   "Monitor0"
              Modeline     "1600x900_60.00"  118.25  1600 1696 1856 2112  900 903 908 934 -hsync +vsync
              VendorName   "Monitor Vendor"
              ModelName    "Monitor Model"

      Section "Monitor"
              Identifier   "Monitor1"
              Modeline     "1600x900_60.00"  118.25  1600 1696 1856 2112  900 903 908 934 -hsync +vsync
              VendorName   "Monitor Vendor"
              ModelName    "Monitor Model"

      Modification #2 — Add modes in screen section in similar way as described above in each subsection (screen1, screen2) under the element Depth (Also for each depth). Example:

      Section "Screen"
          Identifier "Screen0"
          Device     "Card0"
          Monitor    "Monitor0"
          SubSection "Display"
                     Viewport   0 0
                     Depth     1
                     Modes   "1600×900"
          SubSection "Display"
                      Viewport   0 0
                      Depth     4
                      Modes   "1600×900"
          SubSection "Display"
                       Viewport   0 0
                       Depth     8
                       Modes   "1600×900"

      (Upto Depth 24)


      Section "Screen"

       Identifier "Screen1"
          Device     "Card1"
          Monitor    "Monitor1"
          SubSection "Display"
                      Viewport   0 0
                      Depth     1
                      Modes   "1600×900"
          SubSection "Display"
                      Viewport   0 0
                      Depth     4
                      Modes   "1600×900"
          SubSection "Display"
                       Viewport   0 0
                       Depth     8
                       Modes   "1600×900"

          (Upto Depth 24)


    6. Save this file and copy this file to /etc/X11/ by typing following command…

      sudo cp xorg.conf /etc/X11

      … assuming that xorg.conf is located at Home folder, or do it by graphically if you know how.

    Note: New resolution must be less than Maximum resolution that monitor can support. And care fully add those lines to each subsection Monitor0, Monitor1, Monitor2, Monitor3, Screen1, Screen2, Screen3, Screen4. For Screen section, add entries for every Depth from 1, 2, 4, 8, 16, 24.

    The text above was originally posted at LinuxMint Community by Thinker. This also works for Zorin OS, Pinguy OS and many other X.Org based distros.

    Another option is to create the following script, originally made by Danial Rikhteh Garan, and use it.

    1. Open a new file with your text editor and put the text below.

          ### Fix detect display resolution
          ## Please submit feedback and questions at
          ## Danial Rikhteh Garan 2013-04-06

          #### Config ###

          ### Define your suitable resolution that you want (you can get high resolution your display support using just xrandr)
          ## Set it in this format x

          ### Set delay for autostart this script

          ### For find your display name run this command: xrandr
          ## Mine was VGA1

          ### This help may help you for dispaly name (     ##
             # Intel driver – UMS

               # VGA – Analog VGA output
               # LVDS – Laptop panel
               # DP1 – DisplayPort output
               # TV – Integrated TV output
               # TMDS-1 – First DVI SDVO output
               # TMDS-2 – Second DVI SDVO output
               # The SDVO and DVO TV outputs are not supported by the driver at this time.

             # Intel driver – KMS

               # LVDS1 – Laptop panel
               # VGA1 – Analog VGA output
               # DVI1 – Digital video output

             # ATI Radeon driver

               # VGA-0 – Analog VGA output
               # LVDS – Laptop panel
               # S-video – Integrated TV output
               # DVI-0 – DVI output

          sleep $delay
          var=$(xrandr | grep VGA) ; tmp=”${var#VGA?}”; vga=”${var%$tmp}”
          cvt=$(cvt $width $height)
          read -rd ‘ ‘ addMod < <(echo $mod)     xrandr --newmode $mod     xrandr --addmode $vga $addMod     xrandr -s "${width}x${height}"

    2. Don’t forget to change resolution, delay and displayName in the file to your desired values.

    3. Save it somewhere and make it executable (chmod 755 Moving it to /usr/share/bin/ (sudo mv /usr/share/bin would be better, but you can save it anywhere.

    4. In the “Startup Applications” add the script like in the picture below:

      Adding it to Startup Applications

      We assume in the example above that you have saved it to /home/mgr/Script/

    5. Done. Restart your PC or logout and login.

    Hope this could be helpful.


  • Lopo Lencastre de Almeida April 11, 2014, às 15:58 Permalink
    Etiquetas: box linux sync,, , Tutorial   

    Auto mount Box in Linux when you login 

    Unlike Dropbox, Box doesn’t come with any sync software for the personal account. If you upgrade your account to the Business and Enterprise editions, you can download the sync software for Mac and Windows. So if you are using Linux, you are almost out of luck.

    Luckily, Box does support WebDav. This means that you still can connect to it from your Linux desktop, though the solution is not as elegant as the Dropbox sync.

    Here is how you can connect to Box from Linux.

    Note: This tutorial is based on Ubuntu, Gnome Shell and Nautilus.

    Here is one method where you can auto-mount your Box account. We will be using davfs. Here is what you need to do:

    1. Open a terminal and install davfs:

      sudo apt-get install davfs2

    2. Add your Linux user account to the davfs2 group. Replace “your-linux-username” with your Linux login username:

      sudo adduser [your-linux-username] davfs2

    3. According to /usr/share/doc/davfs2/README.Debian, in order to allow other users to use WebDAV run the following and choose the proper option:

      sudo dpkg-reconfigure davfs2

    4. Create a folder in your Home directory to mount your Box account. In addition, also create the .davfs folder to hold your configuration files:

      mkdir ~/Box
      mkdir ~/.davfs2

    5. Next, copy the davfs configuration file over and add the “user_lock” command to it:

      cp /etc/davfs2/davfs2.conf ~/.davfs2
      echo "use_locks 0" >> ~/.davfs2/davfs2.conf

    6. Create a new file in ~/.davfs2 called secrets:

      gedit ~/.davfs2/secrets

      Paste the following, replacing “Box_username” and “Box_password with your Box account login username and password (make sure the quotes around the Box_password remain). Save and close editor: Box_username "Box_password"

    7. Back to the terminal, change the permission of the secrets file so it can only be read/write by you:

      chmod 600 ~/.davfs2/secrets/li>

    8. Next, open the davfs2.conf file (in the .davfs2 folder) with a text editor. Scroll down the list until you find the entry (at around line 24):

      ignore_home kernoops,distccd # system wide config file only

      Insert a # so it becomes:

      #ignore_home kernoops,distccd # system wide config file only

      Next, scroll down further until you find the entry (at around line 35):

      # secrets ~/.davfs2/secrets # user config file only

      Remove the # so it becomes:

      secrets ~/.davfs2/secrets # user config file only

      Save and close the file.

    9. Now, we are going to add a new entry to your /etc/fstab file:

      sudo nano /etc/fstab

      Add the following line to the end of the file (paste using the shortcut key “Ctrl + Shift + v”). Replace “your-linux-username” with your Linux login username: /home/[your-linux-username]/Box davfs rw,user,noauto 0 0

      Save and exit. Open your file manager. You should see a Box entry at the filesystem column (the entry appears, but it is unmounted at the moment, so you won’t be able to access it).

    10. To test if the mounting works, type in the terminal:

      mount ~/Box

      If everything goes fine, your Box account should be mounted and show up in your file manager. If not, check your Box username and password in the secrets file.

      Additional note If you got a 302 or 404 error then check the article Does Box support WebDAV? at to see what may have changed.

    11. Lastly, open up your Startup Applications and add a new item with the command:

      mount ~/Box

    That’s it. Your Box account should be mounted whenever you login to your desktop.

    Original article made by Damien Oh was at but there was some errors that needed to be fixed and comments were closed so I repost it here with errors solved. This is for Linux distros based on Debian. For distros based on RPM or other you need to do the proper adaptations.

    You can also test the Box Linux Sync application made by Noiselabs

  • Lopo Lencastre de Almeida April 7, 2014, às 00:49 Permalink
    Etiquetas: consulting, doing it right, web strategy   

    A Website or an Online strategy? 

    Many businesses want to have a website and decide to engage a company with the experience of carrying it out.

    However, when doing so, companies should have the following sorted out:

    • What are the goals we want to achieve?
    • What is our budget (to achieve these goals)?
    • What will be the impact on our daily operation?

    Designing an online strategy should be directly linked to the strategy of a business, an organization or a project.

    Writing a clear online strategy, in tune with the organization’s goals, adapted to the available resources and generally accepted by staff and other stakeholders is not easy. But it’s necessary and important. (…) An online strategy or web strategy is a live document and a tool to help individuals and teams decide on how to run the organization’s online activity. With a clear online strategy the team can focus on what’s important for the organization and it’s mission. It’s a framework to plan, decide and evaluate tools and processes.1

    Although Osvaldo’s article – from which I took the above excerpts – focuses primarily on the non-profit sector, most of the arguments and checkpoints are still applicable to all sorts of organizations.

    Hence, when companies order a website, they should guarantee that the provider is aligned with their goals and strategy. In the absence of a clear strategy, providers should discuss and help the client to clarify general and online goals. Its also important to clarify and define the audiences the client already speaks to, audiences the client needs to reach, key messages and content strategy, promotion strategy, technology, in-house skills needed, methodologies and teamwork.

    One important aspect will be to adjust the web strategy to the client’s capacity to deal with some of the outcomes: will the client be able to process the increased number of customers or demand generated by its new presence on the web? It’s no use to get more interested customers if you cannot provide them with a service in time and according to their needs. Collapse of the ability to respond to clients may create a negative rebound effect and even loss of customers.

    Much more than a website, the right Internet strategy, well adapted to the clients’ needs and capacity is therefore crucial for business success. Client awareness of such a fact is also the best starting point, for their own sake and for the sake of a better, higher standard web developing industry as a whole.

    1 “Online strategy 101 for non-profits”, Notes on Digital Activism, Osvaldo Gago, August 2011
    This article was first published at DRI in 2013

  • Lopo Lencastre de Almeida March 26, 2014, às 22:28 Permalink
    Etiquetas: , Control key, fronzen gui, , , Magic SysRq key, System software,   

    How to close a program that has frozen the environment 

    Although Linux is a really stable platform, there will be some times that a program will freeze your GUI environment.
    There is an option suitable at cases, when the most common methods will not save you, simply because they are not applicable.

    Sometimes, mostly at games, more specifically at Microsoft Windows games played via Wine but not only, the entire graphical interface freezes.
    Ctrl-Alt-Del and Ctrl-Alt-Backspace are not options, as you want to kill only the faulty game/processes, and at the same time not to lose other running applications/processes.

    The steps to kill the faulty process are:

    1. Open another TTY console of your choice – Press one of Ctrl-Alt-F2 through Ctrl-Alt-F6 sequence;
    2. Login at the console;
    3. Navigate the processes by issuing the command ps -ef | less and find the frozen processes;
    4. Escape from less and kill these processes with the command kill pid1 pid2 ... pidN , substituting the correct values for the PIDs;
    5. Switch and finally return to the original graphical screen by pressing Ctrl-Alt-F7.


  • Lopo Lencastre de Almeida March 21, 2014, às 01:19 Permalink
    Etiquetas: ,   

    Great color scheme designer for webdesigners 

    Check it ou at Color Scheme Designer

  • Lopo Lencastre de Almeida March 18, 2014, às 17:17 Permalink
    Etiquetas: Debian, , Purge Kernels, , Ubuntu Tweak   

    How to Remove All Unused Linux Kernel Headers, Images and Modules 

    Command Line

    Unless you have a totally fresh install of Ubuntu, you have probably noticed that each time you boot up, the GRUB boot menu lists a bunch of previous Linux kernels which you can boot into. While this can occasionally come in handy – like if you can’t boot into the new kernel after an upgrade – those previous kernels, images and modules are usually just wasting space.

    While you can go into Synaptic, search for all the bits and pieces of previous kernels, and mark them for removal, here is a much easier method. In a terminal, simply paste the following command, and it will remove all but the current kernel (if you’ve upgraded your system, or had an update with a new kernel, please reboot your machine before running this):

    dpkg -l 'linux-*' | sed '/^ii/!d;/'"$(uname -r | sed "s/\(.*\)-\([^0-9]\+\)/\1/")"'/d;s/^[^ ]* [^ ]* \([^ ]*\).*/\1/;/[0-9]/!d' | xargs sudo apt-get -y purge

    You will see some info about what is going on:

    The following packages will be REMOVED:
    linux-headers-2.6.35-22* linux-headers-2.6.35-22-generic*
    linux-headers-2.6.35-23* linux-headers-2.6.35-23-generic*
    linux-image-2.6.32-25-generic* linux-image-2.6.35-22-generic*

    0 upgraded, 0 newly installed, 7 to remove and 13 not upgraded.
    After this operation, 586MB disk space will be freed.
    (Reading database … 261863 files and directories currently installed.)
    Removing linux-headers-2.6.35-22-generic …
    Removing linux-headers-2.6.35-22 …
    Removing linux-headers-2.6.35-23-generic …
    Removing linux-headers-2.6.35-23 …
    Removing linux-image-2.6.32-25-generic …

    It will then go on to generate a new GRUB menu, and when you reboot, you’ll see only the current kernel is listed.

    Another option

    You can also check our code [Bash] Purge unused Linux kernel image at With this you only remove the kernel you wish and not all the unused ones.


    IMHO, the best GUI tool is Ubuntu-Tweak

    It is not available from the standard repositories. To install you need to use the author’s PPA:

    sudo add-apt-repository ppa:tualatrix/ppa
    sudo apt-get update
    sudo apt-get install ubuntu-tweak

    Ubuntu Tweak

    Choose the options shown by the arrows.

    Select both the headers and image with the same version number.

    It will not allow you to delete the current kernel you are booted with since the current kernel is not displayed.


    My recommendation is to keep at least two or preferably three kernels including the latest. The reason for the recommendation is that you will have at least one/two other kernels to boot with, if for what-ever reason the latest kernel you are unable to boot with or introducing a regressed capability such as broken wireless.

    partially via Ubuntu Genius and Ask Ubuntu

  • Lopo Lencastre de Almeida March 7, 2014, às 12:20 Permalink
    Etiquetas: agile, , , , tools   

    1369 Best Resources for designers & Developers 

    Stop wasting your time hunting for resources!
    Discover the best resources sorted by popularity. Save your favorites and organize them.

    Check it at Agile Designers

  • Lopo Lencastre de Almeida March 7, 2014, às 03:48 Permalink
    Etiquetas: , , visionaries   

    The difference between how you see agile programming… 

    Agile by Dilbert

    The difference between how you see agile programming, or anything agile, and how your boss sees it…

    PS: And here’s a blog post you might find to be of value: The Lean Analytics Cycle: Metrics > Hypothesis > Experiment > Act (via Avinash Kaushik)

Compose new post
Next post/Next comment
Previous post/Previous comment
Show/Hide comments
Go to top
Go to login
Show/Hide help
shift + esc