User Tools

Site Tools


emis_developer_manual

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
emis_developer_manual [2026/01/02 20:47] ghacheyemis_developer_manual [2026/04/08 07:08] (current) – [[Optional] Various Visual Studio Configuration] ghachey
Line 283: Line 283:
 === Tab vs Spaces Setup === === Tab vs Spaces Setup ===
  
-In VS you can set the handling of tabs for each file type. VS will expand the tab to the number of spaces you specify when the file is displayed. So it doesn't matter what tab size you specify, the file will look nicely indented, if you use the VS option to replace tabs with spacesThis will cause inconsistent indentations when reading the file with any other default tab stop. In particular, you'll see strange behavior when the file is displayed in SourceTree. +Spaces are now to be used instead of tabs. They work better in a world where AI is heavily used. Developers of Pacific EMIS has agreed on:
- +
-The original developers of this project agree to Use Keep Tabs option as shown below for all file types. To do this go into** Tools - Options - Text Editor** settings. +
- +
-This needs to be set for each file type. Developers of Pacific EMIS has agreed on:+
  
   * C#: 4 spaces   * C#: 4 spaces
   * Everything else (CSS/Javascript/TypeScript): 2 spaces   * Everything else (CSS/Javascript/TypeScript): 2 spaces
  
-Below is example of setting up Javascript.+This configuration is enforced using a .editorconfig right in the root of the repository.
  
-{{ :developer-manual:vs-tabs-settings.png }} +CSS you can turn off the hierarchical indentation.
- +
-CSS would be the same as Javascript except you can turn off the hierarchical indentation.+
  
 {{ :developer-manual:css-indentation-configuration.jpg?nolink |}} {{ :developer-manual:css-indentation-configuration.jpg?nolink |}}
- 
-And then C#. 
- 
-{{ :developer-manual:tab-vs-settings-1.png?nolink |}} 
- 
-In SourceTree, the built-in diff viewer always expands tabs as 4 spaces. It works best for seeing what “real” differences are between versions to use the option Ignore Whitespace as shown below. Although the change in white space will not be displayed, it will still be regarded by git as a change to the file. 
- 
-{{ :developer-manual:tab-vs-settings-2.png?nolink |}} 
- 
-Also note these options in Visual Studio under **Edit - Advanced**: 
- 
-  * **Tabify Selected Lines** - converts leading spaces to tabs. Respects the tab size setting in **Tools - Options** when making this conversion. It is recommended to run this on files before submitting a commit. 
-  * **View White Space** - toggle display spaces and tabs (CTRL-E,S) 
  
 ==== Troubleshooting Visual Studio Build/Run Errors ==== ==== Troubleshooting Visual Studio Build/Run Errors ====
emis_developer_manual.txt · Last modified: 2026/04/08 07:08 by ghachey