No desktop? share your virtual terminal hacks

Moderator: Forum moderators

williwaw
Posts: 1948
Joined: Tue Jul 14, 2020 11:24 pm
Has thanked: 172 times
Been thanked: 369 times

No desktop? share your virtual terminal hacks

Post by williwaw »

Other forum posts about terminal apps have rekindled my interest virtual terminals. Some of the apps have been developed for quite a while and have a long usage history, but puppy, being a gui oriented single user OS, does not have a well configured environment for using these apps in a virtual terminal (without X).

Does ctrl-alt F2 bring up a login shell for you? if not
https://forum.puppylinux.com/viewtopic. ... etty#p8353 may be the place to start.

If you have your own bash configs kept at /root/.bashrc, and the prompt you see after you log in is different, your login shell may not be bash. simply type bash at the prompt and you will drop into a new bash shell.

Make a copy of your /etc/inittab for safe keeping, and add some more ttys like so...

Code: Select all

::sysinit:/etc/rc.d/rc.sysinit
tty1::respawn:plogin
tty2::respawn:getty 38400 tty2

tty4::respawn:getty 38400 tty4
tty5::respawn:getty 38400 tty5
tty6::respawn:getty 38400 tty6
tty7::respawn:getty 38400 tty7
tty8::respawn:getty 38400 tty8
tty9::respawn:getty 38400 tty9

::ctrlaltdel:/sbin/reboot

In the above example, tty3 is skipped. On vanilladpup, tty3 is used by X, and ctrl-alt F3 recalls the X session.

console-setup apt install console-setup found in the debian repos, can be used to reconfigure the fonts. It must be run in the virtual terminal after you log in. At the prompt, run dpkg-reconfigure console-setup
If you find something more to your liking, you can write the config to disk by running setupcon at the prompt.

mouse support in a virtual terminal is possible with gpm, apt install gpm
It may have already been installed as a "dependency" if you have previously downloaded midnight commander apt install mc or tilde apt install tilde

User avatar
user1234
Posts: 414
Joined: Sat Feb 26, 2022 5:48 am
Location: Somewhere on earth
Has thanked: 155 times
Been thanked: 90 times

Re: No desktop? share your virtual terminal hacks

Post by user1234 »

Great tips @williwaw :thumbup:. Would like to add something. If you want to change tty from terminal, then use chvt. For example, to change to tty-2-

Code: Select all

chvt 2

Note that if you change to tty-1 and do not have access to changing ttys with keyboard keys bindings, like Ctrl-Alt-F3, then you will be stuck there

PuppyLinux 🐾 gives new life to old computers ✨

geo_c
Posts: 2880
Joined: Fri Jul 31, 2020 3:37 am
Has thanked: 2202 times
Been thanked: 877 times

Re: No desktop? share your virtual terminal hacks

Post by geo_c »

My stock inittab looks like this:

Code: Select all

::sysinit:/etc/rc.d/rc.sysinit
tty1::respawn:plogin
tty2::respawn:getty 38400 tty2
::ctrlaltdel:/sbin/reboot

so I added the line to make this:

Code: Select all

::sysinit:/etc/rc.d/rc.sysinit
tty1::respawn:plogin
tty2::respawn:getty 38400 tty2
tty3::respawn:getty 38400 tty3
::ctrlaltdel:/sbin/reboot

and then changed the /etc/X11/xorg.conf with Option "DontVTSwitch" "false"

Now I will try this without X.

Last edited by geo_c on Sat Jul 16, 2022 2:34 am, edited 1 time in total.

geo_c
Old School Hipster, and Such

geo_c
Posts: 2880
Joined: Fri Jul 31, 2020 3:37 am
Has thanked: 2202 times
Been thanked: 877 times

Re: No desktop? share your virtual terminal hacks

Post by geo_c »

So I exited X, then was at the prompt, which was really nice because the resolution was so high, and mc displayed a lot of files.

Then I entered ctrl-alt-F2, and I got a prompt:

Code: Select all

DPi7 login:

Not knowing what to do I typed: root

then it asked me for a password, and I again didn't know what to do. Maybe I used Xlock one time, and there might be a password for that, but I remembered that the login password for pups is: root. So I tried that, long story short, I couldn't figure out how to get past that prompt.

Where is that password coming from?

geo_c
Old School Hipster, and Such

User avatar
wizard
Posts: 1984
Joined: Sun Aug 09, 2020 7:50 pm
Has thanked: 2650 times
Been thanked: 692 times

Re: No desktop? share your virtual terminal hacks

Post by wizard »

@geo_c

root's default password should be: woofwoof

wizard

Big pile of OLD computers

geo_c
Posts: 2880
Joined: Fri Jul 31, 2020 3:37 am
Has thanked: 2202 times
Been thanked: 877 times

Re: No desktop? share your virtual terminal hacks

Post by geo_c »

wizard wrote: Sat Jul 16, 2022 2:39 am

@geo_c
root's default password should be: woofwoof
wizard

Wow! That was a blast! I have so many terminal apps installed and configured that it was really fun to bounce around. I only added one extra terminal login. I was only using two terminals, but if I opened a file in tilde from midnight commander, then ctrl-alt-F2 to a new terminal and do the same thing with neomutt and elinks, then it began to get a little tricky remembering exactly where I was in the sequence. But man, that feels like a real computer. I'm kind of hooked on that feeling.

So I installed ncmpcpp music player and tag editor/librarian at the suggestion of @williwaw. One nice music program! And I'm on a less recent version of it from the fossapup/ubuntu/debian repo ppm.

Everything that I installed and ran on urxvt in xwin ran great at the command prompt in bash. I didn't enter bash at the prompt (I forgot) but I assumed I was in it, because everything ran so smoothly.

So how do we copy and paste between applications in a terminal environment? I wasn't able to figure it out in xwin urxvt either. I enabled the ctrl-shift-c and ctrl-shift-v key bindings to copy to the xwin clipboard and go between gtk windows and urxvt, but couldn't go from one terminal applicaton to another. So whether in xwin or command prompt, I haven't quite figured out terminal-app to terminal-app cut and paste.

I've got to add some more getty's to the inittab. I think nine should be enough.

geo_c
Old School Hipster, and Such

User avatar
wizard
Posts: 1984
Joined: Sun Aug 09, 2020 7:50 pm
Has thanked: 2650 times
Been thanked: 692 times

Re: No desktop? share your virtual terminal hacks

Post by wizard »

@geo_c

Reminds me a little of the early days of the PC/XT and PC/AT computers before MS Windows. There were "application switchers" like Software Carousel, Switch-It, and even the later MS Dos Shell (file manager) programs that could dynamically switch between DOS programs. I setup several "suites" of word processors, spreadsheet, database, graphic editor, presentation graphics configurations. Some allowed copy and paste between apps. Switch time between apps on an AT class computer with 2mb of ram was about 4 seconds. All of this on a 20mb hard drive (yes that's MB) LOL.

My how times have changed.

wizard

Big pile of OLD computers

geo_c
Posts: 2880
Joined: Fri Jul 31, 2020 3:37 am
Has thanked: 2202 times
Been thanked: 877 times

Re: No desktop? share your virtual terminal hacks

Post by geo_c »

wizard wrote: Sat Jul 16, 2022 1:05 pm

@geo_c

Reminds me a little of the early days of the PC/XT and PC/AT computers... There were "application switchers" like MS Dos Shell. All of this on a 20mb hard drive (yes that's MB) LOL.
wizard

That's funny because when I was a kid my dad worked for IBM and we had some very early hardware in the house. SWTP-6800 was the first. But then we got the PC/XT and I thought it was like magic. Drop down menus! That machine was exactly like yours, 20MB hard drive. But I remember that was an upgrade to the 5 1/4" floppies. Later I had that machine after I was married and I tried to upgrade to 3 1/2" floppies, and I was trying to figure out the jumper settings, and my brother informed that the machine wasn't capable of running a 3 1/2" floppy.

http://dosdays.co.uk/topics/xt_dip_switches.php

Last edited by geo_c on Sat Jul 16, 2022 2:14 pm, edited 1 time in total.

geo_c
Old School Hipster, and Such

geo_c
Posts: 2880
Joined: Fri Jul 31, 2020 3:37 am
Has thanked: 2202 times
Been thanked: 877 times

Re: No desktop? share your virtual terminal hacks

Post by geo_c »

I was explaining to @williwaw that what's interesting is that there are guys like me who had experience with DOS and command line, due to our age and background, but first encountered linux later through xwin, so we come to the terminal/network structure of linux backwards. I first ran Ubuntu, tried a full install, didn't like it, and then stumbled on puppy. I never tried another distro other than puppy-linux after running Lucid. In that regard I'm only now coming to understand the power of linux and it's ssh capabilities and terminal usuage.

And though it seems like an exercise in nostalgia, or curiousity, that's not what's going on. It's about understanding what's under the hood. And frankly I'm using these terminal applications as my daily drivers now. I'm posting in elinks at the moment. I've all but ditched claws mail in favor of neomutt which is running flawlessly. I pick up my rss feeds using newsboat. I'm listening to and fine tuning my 90GB library of mp3's using ncmpcpp and mpd music server. I'm starting to use the ranger file manager in conjuction with midnight commander, as ranger allows for previewing files, and in some ways is structured like a modern pcfilemnan. I've never seen that one mentioned, but found it in a list on a search.

Next I'm looking for a terminal based midi recorder.

geo_c
Old School Hipster, and Such

geo_c
Posts: 2880
Joined: Fri Jul 31, 2020 3:37 am
Has thanked: 2202 times
Been thanked: 877 times

Re: No desktop? share your virtual terminal hacks

Post by geo_c »

@williwaw everything is working swell.

A couple of questions about general protocol. I'm logging into 5 or 6 terminals and entering bash as my first command. Then when I'm done, I figured it's probably a good idea to log out of these terminals. So I type exit to leave bash, then logout to log out of the terminal (which was a lucky guess on my part)

But I leave one terminal logged in, and then type xwin to get back to fossapup desktop.

Is that a good way to do it?

Does it matter which terminal I launch xwin from?

If I leave the terminals logged in, would they still be there if I exit xwin?

Could I conceivably leave applications running in a logged in terminal while running xwin? Would that be a bad idea?

Really just curious at this point. But seems like import stuff to know.

geo_c
Old School Hipster, and Such

williwaw
Posts: 1948
Joined: Tue Jul 14, 2020 11:24 pm
Has thanked: 172 times
Been thanked: 369 times

Re: No desktop? share your virtual terminal hacks

Post by williwaw »

So how do we copy and paste between applications in a terminal environment?

Between one virtual terminal and another? not sure you can, but do you mean to copy and paste text? between files? What application and which other for example?
prior to X, folks found ways to streamline workflows...

I wasn't able to figure it out in xwin urxvt either. I enabled the ctrl-shift-c and ctrl-shift-v key bindings to copy to the xwin clipboard and go between gtk windows and urxvt, but couldn't go from one terminal applicaton to another.

different terminal emulators, gtk apps and browsers are frustrating to me also, especially since I have gotten used to selecting with mouse and pasting with the middle mouse button.
[/quote]

williwaw
Posts: 1948
Joined: Tue Jul 14, 2020 11:24 pm
Has thanked: 172 times
Been thanked: 369 times

Re: No desktop? share your virtual terminal hacks

Post by williwaw »

geo_c wrote: Sat Jul 16, 2022 4:27 pm

@williwaw everything is working swell.

A couple of questions about general protocol. I'm logging into 5 or 6 terminals and entering bash as my first command. Then when I'm done, I figured it's probably a good idea to log out of these terminals. So I type exit to leave bash, then logout to log out of the terminal (which was a lucky guess on my part)

But I leave one terminal logged in, and then type xwin to get back to fossapup desktop.

Is that a good way to do it?

Does it matter which terminal I launch xwin from?

If I leave the terminals logged in, would they still be there if I exit xwin?

Could I conceivably leave applications running in a logged in terminal while running xwin? Would that be a bad idea?

Really just curious at this point. But seems like import stuff to know.

when you boot, you are autologin to root, and then the xsession comes up in another tty.
with vanilla it is tty3 and with easy its tty4, so it varies, and in fact a lot of linuxes use tty6 or 7.

My stock inittab looks like this:

Code: Select all

::sysinit:/etc/rc.d/rc.sysinit
tty1::respawn:plogin
tty2::respawn:getty 38400 tty2
::ctrlaltdel:/sbin/reboot

I would restore my original /etc/inittab and reboot. From the desktop after a fresh boot, test ctrl-alt-f2, f3 f4 f5 etc, to determine which tty fossa wants to use for the x session, and leave it out of your reconstructed inittab, another words, if it is tty3 for example, then you would not want to add a "tty3::respawn:getty 38400 tty3" entry to your new innitab, or want to otherwise use tty3, and for that matter, use tty1 either, if you are using pupmode 13 and expect to find the shutdown dialog in working order at shutdown.
I suppose you can log out of x from the desktop to tty1, then use ctrl-alt-f2 or

user1234 wrote: Thu Jul 14, 2022 12:23 am

Great tips @williwaw :thumbup:. Would like to add something. If you want to change tty from terminal, then use chvt. For example, to change to tty-2-

Code: Select all

chvt 2

Note that if you change to tty-1 and do not have access to changing ttys with keyboard keys bindings, like Ctrl-Alt-F3, then you will be stuck there

to get to a different virtual terminal, but that seems circuitous to me.
I do like the chvt command better then ctrl-alt-Fkey, and find it easiest to open an xterm on the desktop for chvt should if I find my self in a work flow going back and forth from X, but otherwise use ctrl-alt-Fkey between virtual terminals if I am leaving mutt or the music player running.

Last edited by williwaw on Sat Jul 16, 2022 10:27 pm, edited 1 time in total.
williams2
Posts: 1062
Joined: Sat Jul 25, 2020 5:45 pm
Been thanked: 305 times

Re: No desktop? share your virtual terminal hacks

Post by williams2 »

You can use a mouse in a virtual terminal, if the gpm driver is installed and executed.
(see one of the earlier posts in this thread.)

You can have multiple windows , using screens or tmux.
Search for posts by user1111.

You can copy and paste within a terminal.
For example, ctrl+u will delete all text before the cursor, then ctrl+y pastes it (in that window)

One thing you can do is redirect text to a file, then later read it from another terminal.

I think the stuff in readline's config file /etc/inputrc works in a virtual terminal, as well as emulated terminals.
Not sure though.

Usually, sh is your shell. In Puppy, sh is a symlink to bash, but bash behaves slightly differently as sh.
For example, bash might use a file .bash-history and sh might use .history.

You can kill X (from the menu or press ctl+alt+backspace)
then restart the console (the virtual terminal Puppy started from)
by pressing ctl+D or typing exit
You can respawn the console by pressing ctl+D as many times as you want.
Then you can start X again by typing exec xwin,
which would use about 5MB less ram than just typing xwin

You can start multiple instances of X, but you may need a .Xauthority file in /root/

If I leave the terminals logged in, would they still be there if I exit xwin?

Yes, I think so. And if you kill the console by typing exit or ctl+D it will just respawn.
reboot or poweroff would shut down the OS.

Last edited by rockedge on Sun Jul 17, 2022 3:01 am, edited 1 time in total.
Reason: fixed user name affiliation
geo_c
Posts: 2880
Joined: Fri Jul 31, 2020 3:37 am
Has thanked: 2202 times
Been thanked: 877 times

Re: No desktop? share your virtual terminal hacks

Post by geo_c »

williams2 wrote: Sat Jul 16, 2022 10:05 pm

You can use a mouse in a virtual terminal, if the gpm driver is installed and executed.
(see one of the earlier posts in this thread.)

You can copy and paste within a terminal.
For example, ctrl+u will delete all text before the cursor, then ctrl+y pastes it (in that window)

One thing you can do is redirect text to a file, then later read it from another terminal.

I think the stuff in readline's config file /etc/inputrc works in a virtual terminal, as well as emulated terminals.
Not sure though.

Yes, I think so. And if you kill the console by typing exit or ctl+D it will just respawn.
reboot or poweroff would shut down the OS.

I thought about the redirecting text to a file idea. Thanks for these other tips! I don't think I want to start multiple instances of X. I couldn't think of a reason I'd want to do that since it's capable of running all kinds of things at once.

geo_c
Old School Hipster, and Such

geo_c
Posts: 2880
Joined: Fri Jul 31, 2020 3:37 am
Has thanked: 2202 times
Been thanked: 877 times

Re: No desktop? share your virtual terminal hacks

Post by geo_c »

williwaw wrote: Sat Jul 16, 2022 9:57 pm

when you boot, you are autologin to root, and then the xsession comes up in another tty.
with vanilla it is tty3 and with easy its tty4, so it varies, and in fact a lot of linuxes use tty6 or 7.

I would restore my original /etc/inittab and reboot. From the desktop after a fresh boot, test ctrl-alt-f2, f3 f4 f5 etc, to determine which tty fossa wants to use for the x session, and leave it out of your reconstructed inittab

Yes, I left out tty3 in my new inittab. But I decided to do this experiment. I restored back to the original inittab and changed to tty2, then tty4,5,6,7,8,9,10. Nothing happened on 4-10 as expected. But when I tried to tty3, instead of getting the desktop, the system hanged. And I waited, but nothing.

I did that twice. The first time I rebooted with ctrl-alt-del, the second time I was able to switch back to tty2 and autologin root.

so I'm not sure why the system hangs. But I do know that's it tty3 that is trying to go back to the desktop.

Typing xwin brings me back to the desktop fine.

geo_c
Old School Hipster, and Such

williwaw
Posts: 1948
Joined: Tue Jul 14, 2020 11:24 pm
Has thanked: 172 times
Been thanked: 369 times

Re: No desktop? share your virtual terminal hacks

Post by williwaw »

system hangs. But I do know that's it tty3 that is trying to go back to the desktop.
Typing xwin brings me back to the desktop fine.

so tty3 hangs and the shell is waiting..... no input works?
or
you have a prompt in tty3 and xwin is needed as an extra step?

btw, ranger looks nice almost makes me want to brush up on vim key bindings. guess I will need to settle on something universal and newsboat needs to be configured with a text browser and I haven't surveyed the field in years

any preferences or recommendations out there? any browsers that are still maintained?

geo_c
Posts: 2880
Joined: Fri Jul 31, 2020 3:37 am
Has thanked: 2202 times
Been thanked: 877 times

Re: No desktop? share your virtual terminal hacks

Post by geo_c »

Yes, tty3 just gives a blinking cursor at the top left, and no input works, but I can change to another tty.

I have elinks configured for newsboat.

I have lynx on the system also. Elinks is nicer in a lot of aspects. I'm typing from it right now. But sometimes lynx is preferrable. Certain search engines don't work in elinks but do in lynx, and vice versa.

Duck Duck go works great in elinks, and Startpage works great in lynx, but Startpage doesn't work in elinks. Don't know why.

Ranger is nice, I don't have image viewing worked out, but it's still nice as a file browser, and can view text files.

Last edited by geo_c on Sun Jul 17, 2022 5:40 pm, edited 1 time in total.

geo_c
Old School Hipster, and Such

geo_c
Posts: 2880
Joined: Fri Jul 31, 2020 3:37 am
Has thanked: 2202 times
Been thanked: 877 times

Re: No desktop? share your virtual terminal hacks

Post by geo_c »

I almost forgot. In console mode without X, my terminals don't seem to have mouse support. But I do have gpm installed on the system. Is that like a service that I need to start?

I tried starting with:

service gpm start

but that didn't work.

geo_c
Old School Hipster, and Such

williwaw
Posts: 1948
Joined: Tue Jul 14, 2020 11:24 pm
Has thanked: 172 times
Been thanked: 369 times

Re: No desktop? share your virtual terminal hacks

Post by williwaw »

Elinks, thx

Ranger is nice, I don't have image viewing worked out,
my terminals don't seem to have mouse support. But I do have gpm installed

doesnt fossa use a couple of different package managers?
with apt , it not only also installs dependencies, but shows recommended and suggested.
one can also search in html format,
https://packages.debian.org/buster/ranger
possibly? https://screenshots.debian.net/package/caca-utils

not sure if gpm is a service
https://packages.debian.org/buster/gpm

Dry Falls
Posts: 80
Joined: Thu Jul 29, 2021 7:40 pm
Has thanked: 22 times
Been thanked: 43 times

Re: No desktop? share your virtual terminal hacks

Post by Dry Falls »

Gpm needs a service script. This is what I found for rc.gpm in /etc/rc.d:

Code: Select all

/#!/bin/sh
# Start/stop/restart the GPM mouse server:
if [ -x /usr/sbin/gpm ]; then
  MTYPE="imps2"
  if [ "$1" = "stop" ]; then
    echo "Stopping gpm..."
    /usr/sbin/gpm -k
  elif [ "$1" = "restart" ]; then
    echo "Restarting gpm..."
    /usr/sbin/gpm -k
    sleep 1
    /usr/sbin/gpm -m /dev/mouse -t ${MTYPE}
  else # assume $1 = start:
    echo "Starting gpm:  /usr/sbin/gpm -m /dev/mouse -t ${MTYPE}"
    /usr/sbin/gpm -m /dev/mouse -t ${MTYPE}
  fi
fi

You may need to change the MTYPE="" for your pointer device.

You may, depending on puppy verstin, need to start this with

Code: Select all

/etc/rc.d/rc.gpm start

added to rc.local or as a service script in /etc/init.d.

Clarity
Posts: 3829
Joined: Fri Jul 24, 2020 10:59 pm
Has thanked: 1628 times
Been thanked: 523 times

Re: No desktop? share your virtual terminal hacks

Post by Clarity »

geo_c wrote: Sat Jul 16, 2022 4:27 pm

...Does it matter which terminal I launch xwin from?
o
o
o

To answer the several questions: It does NOT matter which VT you launch & if you leave a terminal for another, the program running in the terminal you left will continue. This kind of use of VT has advantages where a monitoring app could be running while you are in a session on anther VT.

AND, of course, if you haven't already discovered, you can run multiple Xwin VT's at the same time while other non-xwin VTs are active with other apps.

And, it is possible to run, BOTH, a XWIN VT AND a WAYLAND VT on the same PC.

Hope this is helpful understanding

williams2
Posts: 1062
Joined: Sat Jul 25, 2020 5:45 pm
Been thanked: 305 times

Re: No desktop? share your virtual terminal hacks

Post by williams2 »

Puppy does not really have run levels, or services, as such.

You can start gpm working something like this:

Code: Select all

gpm -m /dev/input/mice -t imps2

I think gpm automatically runs as a daemon, running in the background.
For debugging you can run gpm with the -D option.

I got gpm from https://packages.debian.org/buster/amd64/gpm/download
then I extracted the files from the deb using uextract
I logged into a virtual terminal,
then ran a shell script with gpm -m /dev/input/mice -t imps2 in the script.
(I have a usb wireless mouse)

Copy and paste using the mouse works well.

You can stop gpm like this killall gpm

Or you can use a script in init.d

geo_c
Posts: 2880
Joined: Fri Jul 31, 2020 3:37 am
Has thanked: 2202 times
Been thanked: 877 times

Re: No desktop? share your virtual terminal hacks

Post by geo_c »

williams2 wrote: Sun Jul 17, 2022 7:57 pm

Puppy does not really have run levels, or services, as such.

You can start gpm working something like this:

Code: Select all

gpm -m /dev/input/mice -t imps2

I think gpm automatically runs as a daemon, running in the background.
For debugging you can run gpm with the -D option.

I got gpm from https://packages.debian.org/buster/amd64/gpm/download
then I extracted the files from the deb using uextract
I logged into a virtual terminal,
then ran a shell script with gpm -m /dev/input/mice -t imps2 in the script.
(I have a usb wireless mouse)

Copy and paste using the mouse works well.

You can stop gpm like this killall gpm

Or you can use a script in init.d

I'll have to work with these lines. It'd be great to have the mouse since so many of the apps I'm using are mouse supported.

Right now I'm hacking around the Ranger file manager. This is one powerful and nice looking manager. It can toggle between a 'Miller' display, and an mc like 'two-pane.' It uses a combination of vim navigation/console integration and proprietary commands and key bindings, and those have a lot capabilities. I'm in xwin at the moment and bouncing between tabs in urxvt. I have the man page for Ranger open in elinks, and the pup-forum also open in elinks, as elinks is tabbed browsing. Ranger is also a tabbed file manager, so it can have multiple tabs on different paths open. Ranger defaults to elinks for opening and viewing, so on one tty console there is a lot of versatility.

So that brings another question to mind. If in one tty login Ranger opens Elinks, and Elinks opens Tilde, does the terminal just suspend applications in a sequence? In other words, is there a limit? If I hypothetically had 6 applications that opened files with other applications, and they were all chained together, something like: start Ranger from midnight commander, view an html from ranger in elinks, open an htm file from elinks with lynx, and open a txt file from lynx with minimum profit, would I then have a chain of suspended applications waiting for the subsequent applications' exit?

mc>ranger>elinks>lynx>mp in this example. 4 applications suspended, and then simply close in reverse mp>lynx>elinks>ranger> to the patiently waiting mc? Or am I liable to crash in that scenario?

geo_c
Old School Hipster, and Such

geo_c
Posts: 2880
Joined: Fri Jul 31, 2020 3:37 am
Has thanked: 2202 times
Been thanked: 877 times

Re: No desktop? share your virtual terminal hacks

Post by geo_c »

geo_c wrote: Sun Jul 17, 2022 9:51 am

I have elinks configured for newsboat.

I have lynx on the system also. Elinks is nicer in a lot of aspects. I'm typing from it right now. But sometimes lynx is preferrable. Certain search engines don't work in elinks but do in lynx, and vice versa.

@@williwaw

I had installed w3m browser a couple days ago, and now I'm using it, and it's got some features that I'm finding hard to resist. A quick strike of the s key brings up buffer history. It seems to display pages in a more appealing layout, and even trees directories and places the files in a kind of paned layout when browsing locally. It displays pics (somewhat) as I'm on the puppy forum using it currently, it displays all the emoji's, and sort of flashes the avatars in urxvt, added: and displays fully in tty. It's good for viewing documents, as it opens all my default apps, whereas elinks seemed to have a hard time dealing with the puppy tmp directory.

I also like the w3m key bindings.

All of these applications take a considerable effort to learn and experiment with, but the payoff is their long standing consistency I suppose. They've been around a long time and don't change much.

geo_c
Old School Hipster, and Such

geo_c
Posts: 2880
Joined: Fri Jul 31, 2020 3:37 am
Has thanked: 2202 times
Been thanked: 877 times

Re: No desktop? share your virtual terminal hacks

Post by geo_c »

Well I posted a lot in this thread, but this is the one thing I haven't got straight:

gpm

My fossapup ppm says gpm is installed, the mouse works great in urxvt.

I created the script /etc/rc.d/gpm.rc then ran the command to start.

That didn't fire up the mouse support. My tty terminals return "gpm no such command"

I tried the /dev line @williwaw suggested. Same response.

I downloaded but didn't install the deb package for gpm, because of the ppm indicating it's already there. Either there is some other config involved, or maybe I should uninstall and try the deb package. Not sure though. Can't work on it again until Tue unfortunately.

Thanks for all the help so far guys. The more I do this the better I get to know the backend of fossapup, and linux in general.

If fossapup has apt installed, I never learned how to use it. That's another piece of the learning curve I need to undertake improving -- command line package management.

geo_c
Old School Hipster, and Such

williams2
Posts: 1062
Joined: Sat Jul 25, 2020 5:45 pm
Been thanked: 305 times

Re: No desktop? share your virtual terminal hacks

Post by williams2 »

I am running BionicPup64.
I'm just saying, this is what I did and it worked for me.

Note: this is a 64bit driver, not a 32 bit driver.

I got the the deb package here https://packages.debian.org/buster/amd64/gpm/download
Just the first deb I tried to dowload, using Firefox.
I think Firefox refused to download it, saying it is a security risk.
I displayed the download list and forced it to download.
That webpage says the deb file is 193K and it has the md5sum so that you can check that it downloaded properly.

I copied the deb file to /tmp/ then extracted the files like this

Code: Select all

cd /tmp/
uextract gpm_1.20.7-5_amd64.deb 

Actually, I typed uex<TAB> gpm<TAB><TAB>
which exracts the files in the deb package.
I found the gmp executable in
/tmp/gpm_1.20.7-5_amd64.deb.extracted/usr/sbin/
which I copied to a dir in the PATH /root/my-applications/bin/

You can check that it works by typing gpm -h

I put a script named m in /root/my-applications/bin/ like this:

Code: Select all

#!/bin/sh
gpm -m /dev/input/mice -t imps2

which works for my wireless usb mouse.

To stop the mouse driver I can type killall gpm
which I could put in a script,
maybe called m0 to stop the mouse driver and m1 to start the mouse driver.

Anyway, gpm seems to work.
I switched to vt2 and it seemed to work well, for copy and paste.
There are other files extracted from the deb.
A script for init.d
A library file, which doesn't seem to be necessary. Maybe it supports more features.

You could start gpm every time Puppy boots, maybe in /etc/rc.d/rc.local

Note: I think the is a small math program named gpm, which is probably not what you want.

Note 2: I do not have a save file, I use an adrv.sfs readonly file to remaster Puppy.
Every time I reboot, it starts up exactly the same as the last boot,
which is good for testing applications and drivers and configurations.

williams2
Posts: 1062
Joined: Sat Jul 25, 2020 5:45 pm
Been thanked: 305 times

Re: No desktop? share your virtual terminal hacks

Post by williams2 »

Right now I'm hacking around the Ranger file manager.

This video is about nnn file manager, and mentions ranger as well.

williwaw
Posts: 1948
Joined: Tue Jul 14, 2020 11:24 pm
Has thanked: 172 times
Been thanked: 369 times

Re: No desktop? share your virtual terminal hacks

Post by williwaw »

@williams2 seems to be the go to guy for gpm troubleshooting.
it just works for me with no input.
guess I will just have to try out all the text browsers. I found one not mentioned yet, https://www.brow.sh/docs/introduction/

open a vt and log in
at the the prompt, type bash, and hit enter
repeat two more times
ctrl-d should return
another ctrl-d should return a second exit
another, a third exit and a fourth and you will log out
you have just created (and left) three bash subshells, similar to what is happening when you called mc>ranger>elinks>lynx>mp
the prior process is not suspended so much, as it is running in higher subshell

you can do the same in urxvt or a script.

geo_c
Posts: 2880
Joined: Fri Jul 31, 2020 3:37 am
Has thanked: 2202 times
Been thanked: 877 times

Re: No desktop? share your virtual terminal hacks

Post by geo_c »

williwaw wrote: Mon Jul 18, 2022 8:30 am

@williams2 seems to be the go to guy for gpm troubleshooting.

I'm gonna say it's an issue that will need actual troubleshooting.

Let's see if I can re-create my attempts at making gpm work.

gpm is built in to fossapup, I confirmed at the third step in the process. Though any console command involving only the built in gpm would return "command not found" or "service doesn't exist"

1st I tried @williams2's method of moving the bin and starting it with the short script. I got a mouse, but not a usable one. It could point, it could click, but it wouldn't open anything. It would simply leave a dead cursor where clicked.

2nd I undid that process, and tried to install the debian package over the top of the pre-built using the puppy package manager. That allowed me to use to the command "service gpm start" and returned that the service had been started. But no mouse activity appeared at all.

3rd I decided to uninstall the debian package (which appeared to be a clean uninstall) and remove the built-in gpm, then re-install the debian package, start the service. The service returned started, but this gave me no mouse at all.

4th I tried to start the debianpackaged gpm mouse using @williams2's short script. This gave me the buggy mouse again. So one thing I didn't try was @Dry Falls service script, but that's because the debian package started up the service.

So no mouse joy yet. Of course I backed up my pupsave before doing all these experiments, now I'm back to ground zero.

geo_c
Old School Hipster, and Such

geo_c
Posts: 2880
Joined: Fri Jul 31, 2020 3:37 am
Has thanked: 2202 times
Been thanked: 877 times

Re: No desktop? share your virtual terminal hacks

Post by geo_c »

williams2 wrote: Mon Jul 18, 2022 8:28 am

Right now I'm hacking around the Ranger file manager.

This video is about nnn file manager, and mentions ranger as well.

Okay, that's one more to check out! Also, I remember looking at browsh. I think I may have tried installing it once. I don't remember any more. I'll look at both of those and get back about it.

geo_c
Old School Hipster, and Such

Post Reply

Return to “Desktop”