ulkas
ulkas

Reputation: 5918

how to align tabs (whitespaces) on github when using eclipse

within eclipse when using inline comments // i do, for my sake, align all the comments at the same position using tabulator, i.e:

$this->site=new openRTB_site($mixed->site);                     //See Site Object       
$this->device=new openRTB_device($mixed->device);               //See Device Object

but when i commit to github and see the file there, some of my lines got broken like:

$this->site=new openRTB_site($mixed->site);                     //See Site Object       
$this->device=new openRTB_device($mixed->device);           //See Device Object

how can i handle this in comfort way? (not using external white space parser)

example of my broken file here: https://github.com/ulkas/openRTBphp4/blob/master/openRTBphp4.php

Upvotes: 0

Views: 226

Answers (2)

gamerson
gamerson

Reputation: 5310

A must have Eclipse tool for dealing with these type of whitespace issues is AnyEdit tools. Especially the Tabs > Spaces and Spaces > Tab conversion features could be useful for your situation.

Upvotes: 0

danilopopeye
danilopopeye

Reputation: 9998

The problem is that GitHub shows each TAB as 8 spaces :)

I can only think in two solutions:

  • change your editor to show each TAB as 8 spaces
  • change your editor to use spaces instead of TAB

Upvotes: 2

Related Questions