{"id":170,"date":"2013-04-22T14:22:26","date_gmt":"2013-04-22T14:22:26","guid":{"rendered":"http:\/\/ri.itservices.manchester.ac.uk\/csf-apps\/?page_id=170"},"modified":"2013-09-09T13:00:28","modified_gmt":"2013-09-09T13:00:28","slug":"editors","status":"publish","type":"page","link":"https:\/\/ri.itservices.manchester.ac.uk\/csf-apps\/software\/applications\/editors\/","title":{"rendered":"Editors"},"content":{"rendered":"<h2>Overview<\/h2>\n<p>In order to submit jobs you need to be able to create and edit text files. A number of editors are installed on the system for this purpose.<\/p>\n<h2>Restrictions on use<\/h2>\n<p>There are no restrictions on accessing editors.<\/p>\n<h2>Set up procedure<\/h2>\n<p>All users have access through their default PATH. There is no need to load any modulefiles.<\/p>\n<h2>Available Editors<\/h2>\n<p>The following editors are available on the CSF. The weblinks will direct you to external documentation, tutorials and FAQs.<\/p>\n<ul>\n<li><a href=\"http:\/\/projects.gnome.org\/gedit\/\">gedit<\/a><\/li>\n<li><a href=\"http:\/\/www.nano-editor.org\/\">nano<\/a><\/li>\n<li><a href=\"http:\/\/thomer.com\/vi\/vi.html\">vi<\/a> and <a href=\"http:\/\/www.vim.org\/\">vim<\/a><\/li>\n<li><a href=\"http:\/\/www.gnu.org\/software\/emacs\/\">emacs<\/a><\/li>\n<\/ul>\n<h2>Windows text files differ from Linux text files<\/h2>\n<p>The CSF runs the Linux operating system. Windows and Linux have different, hidden, ways of indicating new lines. When you create a text file for your batch job submission under windows and transfer it to the CSF your batch job will fail to run because it cannot understand the windows convention. We have three recommended ways of dealing with this if you prefer not to learn a command line based linux editor.<\/p>\n<p>1) Use <code>gedit<\/code> &#8211; although this is a linux editor it is GUI based and can be run directly on the CSF which means you do not need to transfer files back and forth. To use it you will need to run a simple X11 server on your local desktop and enable X11-tunnelling in your SSH connection. Please see the webpage about <a href=\"\/csf2\/getting-started-on-the-csf\/using-the-csf-from-ms-windows\">accessing and using the CSF from windows<\/a> for how to do that and where <code>gedit<\/code> is used as an example. Note that <code>gedit<\/code> won&#8217;t remove or convert existing Windows line ending characters in a file. See option 2 below for that.<\/p>\n<p>2) If you create your text file under windows and upload it to the CSF then run this command on the CSF (at your prompt) <strong>before<\/strong> you submit it to batch:<\/p>\n<pre class=\"in1\">dos2unix <em>filename<\/em><\/pre>\n<p>where <code><em>filename<\/em><\/code> is the name of your file. You should normally only run this on jobscripts, not data files. It is safe to run it on a unix file &#8211; it won&#8217;t change lines that already have the correct unix line ending.<\/p>\n<p>If you wish to check whether there are any lines with the Windows\/DOS line end characters in a file on the CSF, run the following to display those lines:<\/p>\n<pre>\r\ndoslines <em>filename<\/em>\r\n<\/pre>\n<p>3) Under windows use <a href=\"http:\/\/notepad-plus-plus.org\/\">Notepad++<\/a>. In the menu select <code>Edit -> EOL Conversion -> UNIX\/OSX Format<\/code> when creating\/editing a new text file. When you then upload that file the CSF will understand it.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Overview In order to submit jobs you need to be able to create and edit text files. A number of editors are installed on the system for this purpose. Restrictions on use There are no restrictions on accessing editors. Set up procedure All users have access through their default PATH. There is no need to load any modulefiles. Available Editors The following editors are available on the CSF. The weblinks will direct you to external.. <a href=\"https:\/\/ri.itservices.manchester.ac.uk\/csf-apps\/software\/applications\/editors\/\">Read more &raquo;<\/a><\/p>\n","protected":false},"author":2,"featured_media":0,"parent":31,"menu_order":0,"comment_status":"open","ping_status":"closed","template":"","meta":{"footnotes":""},"class_list":["post-170","page","type-page","status-publish","hentry"],"_links":{"self":[{"href":"https:\/\/ri.itservices.manchester.ac.uk\/csf-apps\/wp-json\/wp\/v2\/pages\/170","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/ri.itservices.manchester.ac.uk\/csf-apps\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/ri.itservices.manchester.ac.uk\/csf-apps\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/ri.itservices.manchester.ac.uk\/csf-apps\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/ri.itservices.manchester.ac.uk\/csf-apps\/wp-json\/wp\/v2\/comments?post=170"}],"version-history":[{"count":8,"href":"https:\/\/ri.itservices.manchester.ac.uk\/csf-apps\/wp-json\/wp\/v2\/pages\/170\/revisions"}],"predecessor-version":[{"id":1044,"href":"https:\/\/ri.itservices.manchester.ac.uk\/csf-apps\/wp-json\/wp\/v2\/pages\/170\/revisions\/1044"}],"up":[{"embeddable":true,"href":"https:\/\/ri.itservices.manchester.ac.uk\/csf-apps\/wp-json\/wp\/v2\/pages\/31"}],"wp:attachment":[{"href":"https:\/\/ri.itservices.manchester.ac.uk\/csf-apps\/wp-json\/wp\/v2\/media?parent=170"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}