{"id":53545,"date":"2021-10-05T03:01:41","date_gmt":"2021-10-04T17:01:41","guid":{"rendered":"http:\/\/www.rjmprogramming.com.au\/ITblog\/?p=53545"},"modified":"2021-10-04T15:07:43","modified_gmt":"2021-10-04T05:07:43","slug":"macos-bbedit-text-editor-tutorial","status":"publish","type":"post","link":"https:\/\/www.rjmprogramming.com.au\/ITblog\/macos-bbedit-text-editor-tutorial\/","title":{"rendered":"MacOS BBEdit Text Editor Tutorial"},"content":{"rendered":"<div style=\"width: 230px\" class=\"wp-caption alignnone\"><a target=_blank href=\"http:\/\/www.rjmprogramming.com.au\/Mac\/bbedit_better_than_textedit.jpg\"><img decoding=\"async\" style=\"float:left; border: 15px solid pink;\" alt=\"MacOS BBEdit Text Editor Tutorial\" src=\"http:\/\/www.rjmprogramming.com.au\/Mac\/bbedit_better_than_textedit.jpg\" title=\"MacOS BBEdit Text Editor Tutorial\"  \/><\/a><p class=\"wp-caption-text\">MacOS BBEdit Text Editor Tutorial<\/p><\/div>\n<p>We&#8217;re guilty of neglectful thoughts regarding our coding friend, our laptop text editor of choice.   Yes, you can use one of the IDE text editors for this, but generally speaking, we&#8217;ve preferred (the Mac OS X) TextWrangler text editor we last talked about at <a title='Mac OS X TextWrangler Web Server File Editing Tutorial' href='#mosxtwwsfet'>Mac OS X TextWrangler Web Server File Editing Tutorial<\/a>.  We&#8217;ve ignored for a couple of years now the TextWrangler offer of an upgrade and branding change to the name <a target=_blank title=BBEdit href='https:\/\/www.barebones.com\/products\/bbedit\/?gclid=CjwKCAjwqeWKBhBFEiwABo_XBt1J4WY5QVwetAkyWtjc4OMRkq0Ms2w4vnGEH7J5bKppcTJxpEg3kxoCT0AQAvD_BwE'>&#8220;BBEdit&#8221;<\/a>.  We liked, and found useful, more to the point (good ol&#8217;) TextWrangler.<\/p>\n<p>Moving onto macOS did not change our preference here (for TextWrangler), but, finally, the move to macOS Big Sur saw TextWrangler lassoo its last <strike>ornery<\/strike>ternary expression.  We were tense about the change.<\/p>\n<p>Happily, though, BBEDit is good, and has the same scripting and web server talents as we&#8217;ve talked about with TextWrangler in the past &#8230; so &#8230; yayyyyyyyyy!<\/p>\n<p>Coding HTML and Javascript and CSS, so far, BBEdit has offered us those syntactical niceties like color coding, and adding the (closing) &#8220;}&#8221; after us typing in an (opening) &#8220;{&#8221; <font size=1>(though that &#8220;coffee ahead of you knowing you wanted it service&#8221; is sadly lacking in the current BBEdit version 14.0.1 (416084, 64-bit Intel, sandboxed))<\/font>.<\/p>\n<p><!--p>You can also see this play out at WordPress 4.1.1's <a target=_blank  href='\/\/www.rjmprogramming.com.au\/ITblog\/new-mac-os-x-textwrangler-web-server-file-editing-tutorial\/'>New Mac OS X TextWrangler Web Server File Editing Tutorial<\/a>.<\/p-->\n<hr>\n<p id='mosxtwwsfet'>Previous relevant <a target=_blank title='Mac OS X TextWrangler Web Server File Editing Tutorial' href='\/\/www.rjmprogramming.com.au\/ITblog\/mac-os-x-textwrangler-web-server-file-editing-tutorial\/'>Mac OS X TextWrangler Web Server File Editing Tutorial<\/a> is shown below.<\/p>\n<div style=\"width: 230px\" class=\"wp-caption alignnone\"><a target=_blank href=\"http:\/\/www.rjmprogramming.com.au\/Mac\/twftp.pdf\"><img decoding=\"async\" style=\"float:left; border: 15px solid pink;\" alt=\"Mac OS X TextWrangler Web Server File Editing Tutorial\" src=\"http:\/\/www.rjmprogramming.com.au\/Mac\/twftp.jpg\" title=\"Mac OS X TextWrangler Web Server File Editing Tutorial\"  \/><\/a><p class=\"wp-caption-text\">Mac OS X TextWrangler Web Server File Editing Tutorial<\/p><\/div>\n<p>Working with the rjmprogramming.com.au web server we like any\/all access ideas we come across.  A new idea here came to the top of our mind the other day.  How about editing web server files, like software code ones, in place, working on this MacBook Pro, editing those files residing on the rjmprogramming.com.au domain web server?  In other words, using this idea you don&#8217;t have to have an (s)ftp file tranfser (from MacBook Pro hard disk to rjmprogramming.com.au domain web server (hard disk)) mechanism, such as <a target=_blank title='FileZilla sftp\/ftp' href='https:\/\/filezilla-project.org\/'>FileZilla<\/a> (as we talk about here with <a target=_blank href='https:\/\/www.rjmprogramming.com.au\/ITblog\/windows-ftpmanager-ftp-client-primer-tutorial\/' title='Windows FTPManager Ftp Client Primer Tutorial'>Windows FTPManager Ftp Client Primer Tutorial<\/a>), all the time, necessarily, to do work that is implemented.  Minor progress perhaps, but useful access idea we think.<\/p>\n<p>There&#8217;s another thing about these &#8220;multitudinous&#8221; access ideas.  To have this &#8220;TextWrangler&#8221; text editor method available, is one less &#8220;real&#8221; processing step to have to worry about in the deployment process, and the more you can streamline this the more time you will save for programming, thinking, unit testing and other things programmers are supposed to spend their time doing.<\/p>\n<p>In the Mac OS X (MacBook Pro) &#8220;TextWrangler&#8221; text editor (our favourite) how do you achieve this?<\/p>\n<ol>\n<li>on MacBook Pro open (in whatever way you usually do) the TextWrangler desktop application<\/li>\n<li>File -&gt; Open from FTP\/SFTP Server&#8230;<\/li>\n<li>click Connect&#8230; button<\/li>\n<li>fill in &#8230;\n<ol>\n<li>Server (of domain of website you want access to)<\/li>\n<li>click or not the sftp checkbox (and if checked, the port is likely to be 22)<\/li>\n<li>User (username login to &#8220;Server&#8221;)<\/li>\n<li>Password (password of username login to &#8220;Server&#8221;)<\/li>\n<li>Path (of &#8220;Server&#8221; hard disk, possibly the web server domain&#8217;s Document Root)<\/li>\n<\/ol>\n<\/li>\n<li>click Connect button<\/li>\n<li>highlight web server file of interest<\/li>\n<li>click Open button<\/li>\n<li>all the rest is normal TextWrangler editing of a File except that file happens to be reside on a remote web server and changes you make and File -&gt; Save to  FTP\/SFTP Server&#8230; happens &#8220;in place&#8221; (ie. no transferring required) &#8230; and feel free to view our associated <a target=_blank href=\"http:\/\/www.rjmprogramming.com.au\/Mac\/twftp.pdf\" title=\"Click picture\">PDF slideshow<\/a> for today<\/li>\n<\/ol>\n<p>Cute, huh?!  Access some areas!  Edit in place.  Follow your dream.  Climb every mountain.  Ford every stream.  Follow every rainbow.  <font size=1>T<\/font><font size=1>i<\/font><font size=1>l<\/font><font size=1>l<\/font><font size=3> y<\/font><font size=3>o<\/font><font size=3>u<\/font><font size=5> f<\/font><font size=5>i<\/font><font size=5>n<\/font><font size=5>d<\/font><font size=7> y<\/font><font size=7>o<\/font><font size=7>u<\/font><font size=7>r<\/font><font size=9> d<\/font><font size=9>r<\/font><font size=9>e<\/font><font size=9>a<\/font><font size=9>m<\/font>.<\/p>\n<p>What&#8217;s another &#8220;take home&#8221; from this, for us.  Text editors are great, and the better ones full of interesting features like this.  Think <i>vi<\/i> and its &#8220;make&#8221; functionality as talked about at <a title='Linux vi C make Primer Tutorial' href='#lcpt'>Linux vi C make Primer Tutorial<\/a>.  Think Ultra Edit&#8217;s brilliant compare file functionality as talked about with <a target=_blank href='https:\/\/www.rjmprogramming.com.au\/ITblog\/windows-text-editor-primer-tutorial\/' title='Windows Text Editor Primer Tutorial'>Windows Text Editor Primer Tutorial<\/a>.<\/p>\n<hr>\n<p id='lcpt'>Previous relevant <a target=_blank title='Linux vi C make Primer Tutorial' href='\/\/www.rjmprogramming.com.au\/ITblog\/linux-vi-c-make-primer-tutorial\/'>Linux vi C make Primer Tutorial<\/a> is shown below.<\/p>\n<div style=\"width: 230px\" class=\"wp-caption alignnone\"><a target=_blank href=\"http:\/\/www.rjmprogramming.com.au\/Linux\/vi\/Linux_vi_make.jpg\"><img decoding=\"async\" style=\"float:left; border: 15px solid pink;\" alt=\"Linux vi C make Primer Tutorial\" src=\"http:\/\/www.rjmprogramming.com.au\/Linux\/vi\/Linux_vi_make.jpg\" title=\"Linux vi C make Primer Tutorial\"  \/><\/a><p class=\"wp-caption-text\">Linux vi C make Primer Tutorial<\/p><\/div>\n<p>The Linux (or unix) command <a target=_blank title='vi' href='http:\/\/pic.dhe.ibm.com\/infocenter\/zos\/v1r13\/topic\/com.ibm.zos.r13.bpxa400\/vi.htm?resultof=%22%76%69%22%20'><i>vi<\/i><\/a> is a powerful command line editor tool which has a long history with unix and the maintenance of C code (as just one example of its uses).<\/p>\n<p>So much so, as far as C coding goes, that the creators of <i>vi<\/i> clearly thought you may &#8220;set up shop&#8221; in the <i>vi<\/i> world, because, if you have a makefile, like our <a target=_blank href=\"http:\/\/www.rjmprogramming.com.au\/Linux\/vi\/makefile._GETME\" title='makefile'>simple one<\/a> for today&#8217;s tutorial, you can use <i>vi<\/i>&#8216;s :<i>make<\/i> command to compile your C or C++ code while in <i>vi<\/i> &#8230; for those thinking that they never &#8220;make&#8221; syntax errors in C &#8230; hope you know where all the <a target=_blank href='https:\/\/www.youtube.com\/watch?v=A0xTEUBEQUs' title='Kryptonite'>Kryptonite<\/a> supplies are?<\/p>\n<p>You&#8217;ll notice that you can run that compiled code (if successful) and still not leave <i>vi<\/i> via :<i>!.\/Hello<\/i> (where the ! is taking you to the parent shell).<\/p>\n<p>There are other text editors for command line Linux (or unix), some being <a target=_blank title='pico' href='http:\/\/info.eps.surrey.ac.uk\/FAQ\/pico.html'>pico<\/a> and <a target=_blank title='emacs' href='http:\/\/www.cs.colostate.edu\/helpdocs\/emacs.html'>emacs<\/a>, and there is a bigger version of vi called <a target=_blank title='vim' href='http:\/\/www.vim.org\/'>vim<\/a>.<\/p>\n<p>The thing about a lot of command line text editors is that they look unfriendly (it&#8217;s less unfriendly if you know {ESC}: gets you to the : prompt from the screen view &#8230; second green arrow in tutorial picture included this), and that can be true, and this has lead me to do more work with the GUI <a target=_blank href='http:\/\/www.macupdate.com\/app\/mac\/11009\/textwrangler' title='Mac TextWrangler text editor'>TextWrangler<\/a> (when on a Mac) if there is going to be much cutting, copying and pasting, but you should know that <i>vi<\/i> has functionality to do with buffers, and some years back, there were maybe 6 or 7 days I&#8217;d have preferred to do copying and pasting between buffers using <i>vi<\/i> &#8230; you&#8217;re right &#8230; I&#8217;ll <a target=_blank href='https:\/\/www.youtube.com\/watch?v=BF6ffbz70SY' title='Take a Bex and lie down'>&#8220;take a Bex&#8221;<\/a> and lie down now.<\/p>\n<p>Here is a link to some downloadable C code you could call <a target=_blank href=\"http:\/\/www.rjmprogramming.com.au\/Linux\/vi\/Hello.c_GETME\" title='Hello.c'>Hello.c<\/a> and its associated <a target=_blank href=\"http:\/\/www.rjmprogramming.com.au\/Linux\/vi\/makefile._GETME\" title='makefile'>makefile<\/a> designed for Linux command line compilation via <a target=_blank title='vi' href='http:\/\/gcc.gnu.org\/'><i>gcc<\/i><\/a> (and here is a good tutorial regarding <a target=_blank href='http:\/\/stackoverflow.com\/questions\/1484817\/how-do-i-make-a-simple-makefile-gcc-unix' title='gcc makefiles'>makefiles<\/a> for <i>gcc<\/i> compiler &#8230; thanks).<\/p>\n<p>If this was interesting you may be interested in <a title='Click here to see topics in which you might be interested' href='#d8497' onclick='var dv=document.getElementById(\"d8497\"); dv.innerHTML = \"&lt;iframe width=670 height=600 src=\" + \"http:\/\/www.rjmprogramming.com.au\/wordpress\/?tag=text-editor\" + \"&gt;&lt;\/iframe&gt;\"; dv.style.display = \"block\";'>this<\/a> too.<\/p>\n<div id='d8497' style='display: none; border-left: 2px solid green; border-top: 2px solid green;'><\/div>\n<hr>\n<p>If this was interesting you may be interested in <a title='Click here to see topics in which you might be interested' href='#d38693' onclick='var dv=document.getElementById(\"d38693\"); dv.innerHTML = \"&lt;iframe width=670 height=600 src=\" + \"https:\/\/www.rjmprogramming.com.au\/ITblog\/tag\/sftp\" + \"&gt;&lt;\/iframe&gt;\"; dv.style.display = \"block\";'>this<\/a> too.<\/p>\n<div id='d38693' style='display: none; border-left: 2px solid green; border-top: 2px solid green;'><\/div>\n<hr>\n<p>If this was interesting you may be interested in <a title='Click here to see topics in which you might be interested' href='#d53545' onclick='var dv=document.getElementById(\"d53545\"); dv.innerHTML = \"&lt;iframe width=670 height=600 src=\" + \"https:\/\/www.rjmprogramming.com.au\/ITblog\/tag\/text\" + \"&gt;&lt;\/iframe&gt;\"; dv.style.display = \"block\";'>this<\/a> too.<\/p>\n<div id='d53545' style='display: none; border-left: 2px solid green; border-top: 2px solid green;'><\/div>\n","protected":false},"excerpt":{"rendered":"<p>We&#8217;re guilty of neglectful thoughts regarding our coding friend, our laptop text editor of choice. Yes, you can use one of the IDE text editors for this, but generally speaking, we&#8217;ve preferred (the Mac OS X) TextWrangler text editor we &hellip; <a href=\"https:\/\/www.rjmprogramming.com.au\/ITblog\/macos-bbedit-text-editor-tutorial\/\">Continue reading <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[12,29,37],"tags":[3811,1849,319,2570,1822,585,725,2178,997,1105,1254,1255,1265,1319],"class_list":["post-53545","post","type-post","status-publish","format-standard","hentry","category-elearning","category-operating-system","category-tutorials","tag-bbedit","tag-coding","tag-desktop","tag-edit","tag-editor","tag-ide","tag-mac-os-x","tag-macos","tag-programming","tag-script","tag-text","tag-text-editor","tag-textwrangler","tag-tutorial"],"_links":{"self":[{"href":"https:\/\/www.rjmprogramming.com.au\/ITblog\/wp-json\/wp\/v2\/posts\/53545"}],"collection":[{"href":"https:\/\/www.rjmprogramming.com.au\/ITblog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.rjmprogramming.com.au\/ITblog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.rjmprogramming.com.au\/ITblog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.rjmprogramming.com.au\/ITblog\/wp-json\/wp\/v2\/comments?post=53545"}],"version-history":[{"count":3,"href":"https:\/\/www.rjmprogramming.com.au\/ITblog\/wp-json\/wp\/v2\/posts\/53545\/revisions"}],"predecessor-version":[{"id":53548,"href":"https:\/\/www.rjmprogramming.com.au\/ITblog\/wp-json\/wp\/v2\/posts\/53545\/revisions\/53548"}],"wp:attachment":[{"href":"https:\/\/www.rjmprogramming.com.au\/ITblog\/wp-json\/wp\/v2\/media?parent=53545"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.rjmprogramming.com.au\/ITblog\/wp-json\/wp\/v2\/categories?post=53545"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.rjmprogramming.com.au\/ITblog\/wp-json\/wp\/v2\/tags?post=53545"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}