Development > Scripting and Bash

ls /dev

<< < (2/4) > >>

Moltke:

--- Quote from: trinidad on September 23, 2018, 11:31:01 AM ---@Moltke wrote: "text editor I use the most is nano, yeah nano all the way"
I agree. Use Nano a lot myself for BASH stuff, and whatever other editor is available depending on the OS when it's necessary to be out of the CLI, and I use only Gvim for other code bases like ruby and js. I don't know if it's an attempt at a teaching method, but in a lot of tutorials I see text editors recommended for basically no particularly important reason when nano would be the easiest. Small changes might as well use a small editor.

TC


--- End quote ---

@trinidad  Yeah, nano's the one I always use the most. I very often find myself typing
--- Code: ---$ nano somefile
--- End code ---
in a terminal. I'm so used to it and have learned its key shortcuts...well most of them  8) Vim, Vi, Gvim I've always wanted to learn how to use Vi/Vim since I read a lot of articles claiming its not just one more editor but THE EDITOR LOL, but its "user unfriendliness" makes me always type the one Vi/Vim command I ever learnt :q!  ;D

@bitsnpcs I can only say: WOW! Nicely done girl! Like I said in a previous post I'm just learning how to create GUIs with python  ;D using those two programs I told you about.

bitsnpcs:
Thank You @Moltke  :)   it is on Github, if you want, I made gui in way so I (and others) can make other GUI from this easily by copy/paste and edit.

Earlier I made some Gimp edits to try and better show how the thought image and book commands arrived in 1 thought. It took me a lot longer to try and do this.

Maybe it helps someone if it is interesting, it is not a project, or meant to be accurate, it is just showing the process of my thought as images when learning.


The image/thought was based on Systemback as this is the only backup software my eyes had seen.









The image didn't have the highlight, I just use it to show the description below of commands from book and the ideas of how I thought they might be able to be used from a beginner perspective, but likely wrong lol.

1 -  ls -t /directory/of/images       display image filenames of backups made of HOME at #3, and list by date order.

2 - ls /dev/sd*    output destination box, drop down menu for selection of sd* locations

3 - ??  needs command to create an image file from collection of HOME directory contents

4 - dd if=/dev/sdb of=flash_drive.img        need to change command to make image of entire OS not of the example flash_drive

5 - ??  run install media from #4

6 - dd if=input_file of=output_file [bs=block_size [count=blocks]]         where input file is output of/ or stored image of  #4

7 - sudo fsck /location/of/file system          file system check and repair

8 - sudo apt-get update
     sudo apt-get upgrade

9 - add embedded text window, mirroring the terminal output inside the GUI from #6 so any errors are visible.


@Moltke maybe now you can see why I said it was just thoughts based on the commands as I don't know enough to do this, many others would know though.
After the image thought, in popped its description thought -

"Bubl is a blend of LL, Cli, Python and Tk, cooked at 420F and seasoned with Love :) "

trinidad:
@Moltke wrote: "text editor I use the most is nano, yeah nano all the way"
I agree. Use Nano a lot myself for BASH stuff, and whatever other editor is available depending on the OS when it's necessary to be out of the CLI, and I use only Gvim for other code bases like ruby and js. I don't know if it's an attempt at a teaching method, but in a lot of tutorials I see text editors recommended for basically no particularly important reason when nano would be the easiest. Small changes might as well use a small editor.

TC

Moltke:
That GUI looks really good! Nice job @bitsnpcs  :)


--- Quote ---No not trying to create anything at the moment, I am working through the book, "The Linux Command Line", unsure how many years ago I began it...You can get The Linux Command line as pdf free from the official site http://linuxcommand.org/tlcl.php
--- End quote ---
I see. I too started reading that book a while ago and for some reason stopped doing it, guess I got stuck at that moment. Thanks for the link by the way.


--- Quote ---I use LL, and Gedit for Python coding
--- End quote ---
I used to use gedit too, then tried geany, they both are fine but then I discovered sublime text and find it really nice; lightwight, handy features, easy to use. In the past I've used kate even in windows 7, which is a great editor but now I try to avoid having those kde dependencies and who knows, sometimes I fell like installing it  ::)  Althought, the text editor I use the most is nano, yeah nano all the way. Now that I think of it, nano's the reason I never really care too much for text editors.


If you fell like trying sublime text, here are the steps for installing it:


First, open a terminal and type
--- Code: ---$ wget -qO - https://download.sublimetext.com/sublimehq-pub.gpg | sudo apt-key add -
--- End code ---




--- Code: ---$ echo "deb https://download.sublimetext.com/ apt/stable/" | sudo tee /etc/apt/sources.list.d/sublime-text.list
--- End code ---



--- Code: ---$ sudo apt-get update
--- End code ---



--- Code: ---$ sudo apt-get install sublime-text
--- End code ---



Or, you can simply read more about it on its website http://www.sublimetext.com/


Cheers! :)

bitsnpcs:
Thank you for the links @Moltke  :)
No not trying to create anything at the moment, I am working through the book, "The Linux Command Line", unsure how many years ago I began it, I began to use Linux (Linux Lite right from the very start) 4 years ago from July 2018. But only started to use Linux and no Windows after a few of those years.
I learn some bits then do other things. When I feel ready then I learn some more. I am just beginning Chapter 17.

I use LL, and Gedit for Python coding, I then test the Python in the terminal before making the GUI, I build the GUI afterwards by editing and typing it in to the Python code in its file.
If you have not seen it this was my first completed Python app and GUI I made, I done it on LL using Gedit, Terminal, Python, and Tkinter. I am really pleased I was able to finish the first one because it will encourage me in future projects, not to give up easily.




Overall in the chapter of book I learned about the storage commands to -
1. make files or folders in to an image
2. command to burn that image/ISO
3. how to clone hard drive to another hard drive
4. how to view what occurs when device is added to the system.

Later that night I was listening to music and looking at the chapter index of contents for next few chapters, a future one is about "archives and backups", my mind thought, you have already learned about backup software, then the thought of commands 1thru 4 and how it may not be too difficult the extra things to learn to make this in Python into a backup software, for files/directories, cloning hard drives, and output it to external media, like portable hard drive or flash drive for files and directories.

Later I thought maybe as a stepping stone to that making an app GUI for burning ISO to disc, or saving to USB could be a practice run, but to make it final /usable gui on its own in case someone liked it or wanted to use it in part of another project.

It was just thoughts of the basic outline of what was needed.

You can get The Linux Command line as pdf free from the official site http://linuxcommand.org/tlcl.php

Navigation

[0] Message Index

[#] Next page

[*] Previous page

Go to full version