lalbornoz / PuTTie

PuTTie loves you 💚
Other
52 stars 0 forks source link

PuTTie 💚

socks cat courtesy of sad
PuTTY plus pointless frippery and tremendous amounts of bloat[1][2][3][4][5][9]

Table of contents

  1. What is PuTTie, and how is it different?
  2. Screenshot
  3. List of newly introduced features
  4. Jump list integration
  5. Thanks to
  6. Built with & tested on
  7. How to build
  8. TODO/wish list
  9. Pull requests policy
    1. References

What is PuTTie, and how is it different?

Unlike the other extant and past PuTTY forks, PuTTie is meticulously engineered such as to minimise the amount and quality of changes required to the actual PuTTY pigsty ~~incoherent heap of rotten, fermenting bat manure~~ source code, yet without sacrificing in range of features or the lack of quality of their implementation.

This is additionally required as PuTTY's upstream is ~~an insecure, socially inept, belligerent, obstinate, covetous arsehole~~ particularly hostile to both users, change, reality, contributors, as well as maintainers of PuTTY forks. As PuTTie has shown to have, over the course of its existence since late June 2018, very low maintenance cost, it is much less likely to succumb to the inevitability of bit rot and loss of maintainers.

Still not convinced? Here are six (6) extremely convincing reasons why you should use PuTTie:

  1. It's really cute!

  2. It has a green heart next to its really cute name because PuTTie loves you!

  3. It can totally dance the Melbourne shuffle!

  4. kade, nadia, roarie and arab like PuTTie:
    kade, nadia, roarie and arab like PuTTie!

  5. It stabilises your Estradiol and Progesterone levels ~~kindly tells your hypothalamus to be nice~~ gives your Estrogen Receptors a hug so they won't feel underappreciated when they're like doing a lot of hard work and adapting to and/or driving (if you don't actually have the whole reproductive bits and stuff) highly dynamic hormonal circumstances and totally prevents PMS/PMDD as long as you use it all day long for three (3) days without sleeping or eating!

  6. The following people/deities have found PuTTie to have been critical to their immeasurable contributions to {woman,man,non-binary-,egg-}kind in general:

    kade, nadia, roarie, Brigadier-Sergeant Corporal Erran Morad, Tupac Shakur, Rainer Maria Rilke, Big L, Michael Ende, Taktlo$$, Omar Souleyman, King Kool Savas, Christian J. Kiewiet, David N. Cutler Sr., Usāmah b. Muḥammad b. Awaḍ bin Lādin, Kāẓim Finjān al-Ḥammāmi, Aḥmad al-Asīr, James Thomas "Baby Huey" Ramey, Federico García Lorca, Miguel de Unamuno y Jugo, Fyodor Dostoevsky, Immanuel Kant, Ivan the Terrible, Geoffrey Chaucer, the bloke what made Sir Gawain and the Green Knight but he said I'm not supposed to share his name, Moses Šem-Ṭо̄v de León, Šəlо̄mо̄ b. Yəhūḏā b. Gābīrо̄l, Abū Muḥammad ʿAlī b. Ḥazm, Abū Ḥāmid al-Ġazālī, Abū al-Ṭayyib Aḥmad al-Mutanabbī, ʿubādah al-Qazzāz, Abū ʿUthman ʿAmr al-Jāḥiẓ of Baṣrah, ʿAbd al-Malik al-Aṣmaʿī, Heraclitus of Ephesos, Parmenides of Elea, Ecclesiastes, none of the Biblical Patriarchs because most of them either never existed anyway and/or were appropriated from old Mesopotamia for the purposes of ramming divine sovereignty of a lower Canaanite deity down everyone's throats, Sīn-lēq-unnínni, Mursili I, despite his anger issues, Šubši-mašrā-šakkan, bonus points for having a badass name, ʿammu Rāpī the Amorite, utilising the ST100 ancestor of VT100, Šarrukīn I of Akkad, all of the Anunnaki, except for Ellil because he doesn't know how be nice to people, Ištar the Lioness, Goddess of Transness and stuff, Gudea of Lagaš, Wendy Carlos, and Cardi B.

    Don't you want to be like them? (except for Ellil because he's an arsehole)

Back to top

Screenshot

Screenshot

Back to top

List of newly introduced features

  1. Background {BMP,EMF,GIF,ICO,JPEG,PNG,TIFF,WMF}[10] images, similarly to[6]
    Absolute positioning, centered, fit w/ optional padding, scaled, or tiled, with configurable opacity
    Melbourne shuffle slideshow with configurable frequency, updated automatically on file changes in images directory
  2. Trans-arency, similarly to the mintty[7] implementation
    Optionally in conjunction with background images, configurable opacity on {focus,focus loss} behaviour
  3. Clickable URLs, similarly to the mintty[7] implementation
    Configurable URL regular expressions via pcre2[12] and ShellExecute()[24]
    Configurable ShellExecute() browser application[24]
    Configurable mouse motion and LMB click modifiers: \<Ctrl>, \<Alt>, \<RightAlt|AltGr>, \<RightCtrl>, and optionally as well as additionally \<Shift> or \<RightShift>
    Configurable underline and/or reverse video on highlight/click, resp. behaviour
    Regular expressions may contain/match on whitespaces, etc. pp.
    Extend/shrink URL selection for URLs spanning multiple lines prior to opening URL with mouse wheel and configurable (defaults to \<Alt>) modifier key
  4. Change font size with \<Ctrl> + \<Mouse wheel>, similarly to the mintty[7] and PuTTYTray[11] implementations
    Optionally, \<Ctrl> 0/+/- will also reset/increase/decrease the font size; this feature may be turned on or off (default) from the Frippery -> Mouse panel.
  5. Always on top, similarly to the PuTTYTray[11] implementation
  6. Minimise to system tray[2], similarly to[11]
  7. Store configuration in disk files[1], similarly to[11]
    Selectable w/ command-line option --file in plink, pscp, psftp, pterm, putty & puttytel
    Additionally, file storage may be initialised from the registry w/ the command- line option --file=registry

    User interfaces are provided within putty & puttytel to clean up, clear, copy, delete, migrate, rename, and move sessions, host CAs, host keys, and the persistent Pageant private key and jump lists and global options from/to all storage backends (ephemeral, file, registry)

    The disk file configuration tree is, by default, rooted at %APPDATA%\PuTTie\. This can be changed on a per-session and descendant duplicated session basis with the command-line option suffix ;[~]<absolute/relative pathname>, with the optional ~ prefix substituted with the pathname to the PuTTie executable image file, e.g.: --file=registry;..\data\PuTTie_stuff, --file=;~, --file=;~\..\..\PuTTie_backup, etc.

    Additionally, the default backend is set from the filename of the plink, pscp, psftp, pterm, putty & puttytel executable image file when the filename matches one of: *-ephemeral.exe, *-file.exe, *-portable.exe, *-registry.exe, with *-portable.exe selecting the file backend and passing ~ as per-session file configuration tree, e.g. the pathname to the executable image file.

  8. Store configuration in ephemeral storage
    Selectable w/ command-line option --ephemeral in plink, pscp, psftp, pterm, putty & puttytel
    Additionally, ephemeral storage may be initialised from disk files or the registry w/ the command- line options --ephemeral=file and --ephemeral=registry, respectively
    User interfaces are provided within putty & puttytel to clean up, clear, copy, delete, migrate, rename, and move sessions, host CAs, host keys, the persistent Pageant private key and jump lists and global options from/to all storage backends (ephemeral, file, registry)

    N.B. The random seed file PUTTY.RND stored beneath %LOCALAPPDATA% is still read from, if present, on startup and written to on exit due to security concerns, even when ephemeral storage is selected.

    Additionally, the default backend is set from the filename of the plink, pscp, psftp, pterm, putty & puttytel executable image file when the filename matches one of: *-ephemeral.exe, *-file.exe, *-portable.exe, *-registry.exe, with *-portable.exe selecting the file backend and passing ~ as per-session file configuration tree, e.g. the pathname to the executable image file.

  9. Persist Pageant private key file names across startups
    A list of private key files is stored in file- or registry-based storage to persist key files added to Pageant across startups. This list is updated on adding or removing keys and may additionally be set from the command line by passing any number of path- or filenames to Pageant as arguments.

    This feature may be turned on or off (default) from Pageant's system tray menu.

  10. Launch Pageant at Windows startup
    This feature may be turned on or off (default) from Pageant's system tray menu.
  11. GUI, configuration & storage internationalisation
    Text strings in the GUI, configuration & storage thereof, including sessions, etc. may contain anything that encodes from/to valid UTF-16/UTF-8 and vice versa; UTF-16 is used at and due to Windows API boundaries, UTF-8 internally as well as in file contents.
  12. Cache passwords
    Caches SSH2 passwords in memory across session restarts and session duplication. This is disabled by default and can be enabled in the Frippery panel.
    WARNING: If and while enabled, this will cache passwords in memory insecurely. Consider not using this on shared computers.
  13. Automatic session restart on disconnect
    This is disabled by default and can be enabled in the Frippery panel.
  14. putty.exe help screen
    Pass any of: -?, -h, --help.
  15. Remember last configuration window position
  16. Duplicate current session with \<Ctrl> \<Shift> LMB, similarly to the KiTTY[27] implementation
    This is disabled by default and can be enabled in the Frippery panel.

Back to top

Jump list integration

PuTTie fixes bugs (particularly [25]) in PuTTy's jump list integration implementation. Owing to how shortcuts are specified to interact with jump lists, PuTTie shortcuts must have the Application User Model ID[26] common to both PuTTie and PuTTY set on them. A jump list-compatible shortcut creation tool is provided for this purpose. Follow the following steps in order to create such a shortcut:

  1. Extract the contents of the PuTTie release archive into a directory that will neither change name nor location in the future, such as %APPDATA%\PuTTie or %LOCALAPPDATA%\PuTTie, etc. If this directory is renamed and/or moved, steps 2. and 3. must be repeated.

  2. Run create_shortcut.exe from within this directory. A message box will be displayed on exit or failure. If it exits successfully, a shortcut named PuTTie.lnk by default will now exist in the same directory; the tool takes two optional arguments, corresponding to the file or path name of the shortcut and the file or path name to putty.exe.

  3. The shortcut created in 2. may now be pinned to the Start menu via the context menu.

Back to top

Thanks to

Thanks to James Watt, SamKook, opbod, jslegers73, lars18th for helping fixing lots of bugs!

Back to top

Built with & tested on

  1. MinGW w/ GCC v11.3.0 & cmake v3.23.2 on Cygwin v3.4.2-1 & Windows 8.1 x64, resp.
  2. MinGW w/ GCC v10-win32 20220324 & cmake v3.24.2 on Ubuntu v22.10 & wine-7.0 (Ubuntu 7.0~repack-8)

Back to top

How to build

$ git clone --recurse https://github.com/lalbornoz/PuTTie

#
# Release build, create release archive, no build parallelisation/max. 4 jobs, resp.:
$ ./PuTTie/build.sh distclean_all and install
$ ./PuTTie/build.sh -j 4 distclean_all and install

#
# Debug build, create release archive, no build parallelisation/max. 4 jobs, resp.:
$ ./PuTTie/build.sh -d distclean_all and install
$ ./PuTTie/build.sh -d -j 4 distclean_all and install

#
# Release build, default to file as storage backend, create release archive, no build parallelisation/max. 4 jobs, resp.:
$ ./PuTTie/build.sh -B file distclean_all and install
$ ./PuTTie/build.sh -B file -j 4 distclean_all and install

#
# Help screen:
$ ./PuTTie/build.sh -h
usage: build.sh [-B <backend>] [-d] [-D] [-h] [-i] [-j <jobs>] [-t <target>]
      [<command> [<args>[...]] [and] [...]

      -B <backend>....: set default storage backend to either of ephemeral, file, or registry (default)
      -d..............: select Debug (vs. Release) build
      -D..............: select Debug w/o debugging console (vs. Release) build (for usage w/ dbg_server)
      -h..............: show this screen
      -i..............: ignore command dependencies
      -j <jobs>.......: set cmake(1) max. job count; defaults to processor count in /proc/cpuinfo on Linux
      -t <target>.....: build <target> instead of default target

Available commands:
clang_compile_cmds      Create compile_commands.json file
clean                   Clean PuTTie build directory
clean_all               Clean pcre2 and PuTTie build directory
clean_pcre2             Clean pcre2 build directory
configure               Configure PuTTie
configure_pcre2         Configure pcre2
dbg_client [...]        Attach to gdbserver on localhost:1234 with optional arguments to gdb
dbg_server [...]        Start gdbserver on localhost:1234 with optional arguments to putty.exe
distclean               Reset PuTTie build directory
distclean_all           Reset pcre2 and PuTTie build directory
distclean_pcre2         Reset pcre2 build directory
make                    Build PuTTie
make_pcre2              Build pcre2
install                 Create PuTTie release archive
publish                 Publish PuTTie release archive on GitHub

N.B.: When switching build types, run clean.

Back to top

TODO/wish list

  1. New feature: Direct{2D,Write} backend, similarly to[21]
  2. New feature: MS Visual C++ build environment support bits via Winelib & provide installer package(s) & images
  3. New feature: ssh:// protocol handler registration, similarly to[19]
  4. New feature: ReGIS[22] and/or Sixel[23] terminal graphics support

Back to top

Pull requests policy

Pull requests are accepted & welcomed, unless you're Simon Tatham, Owen Dunn, Ben Harris, or Jacob Nevins.

Back to top

References

Wed, 20 Jun 2018 11:11:13 +0200 [1] PuTTY wish config-locations
Wed, 20 Jun 2018 11:11:14 +0200 [2] PuTTY wish system-tray
Wed, 20 Jun 2018 11:11:15 +0200 [3] PuTTY wish transparency
Wed, 20 Jun 2018 11:11:16 +0200 [4] PuTTY wish url-launching
Wed, 20 Jun 2018 11:11:17 +0200 [5] PuTTY Known Bugs and Wish List, heading: Non-wish list
Wed, 20 Jun 2018 11:11:18 +0200 [6] putty-trans.diff
Wed, 20 Jun 2018 11:11:19 +0200 [7] mintty/mintty: The Cygwin Terminal – [...]
Wed, 20 Jun 2018 11:11:20 +0200 [8] Project status · Issue #278 · FauxFaux/PuTTYTray
Wed, 20 Jun 2018 11:11:21 +0200 [9] PuTTY hacking guide
Thu, 21 Jun 2018 13:51:41 +0200 [10] Using Image Encoders and Decoders in Managed GDI+ | Microsoft
Thu, 21 Jun 2018 14:37:54 +0200 [11] PuTTYTray
Fri, 27 Aug 2021 18:27:53 +0200 [12] GitHub - PhilipHazel/pcre2: PCRE2 development is now based here.
Fri, 22 Jun 2018 14:51:14 +0200 [13] KiTTY - Welcome
Fri, 22 Jun 2018 14:56:33 +0200 [14] [...] PuTTY Transparency
Fri, 22 Jun 2018 14:58:09 +0200 [15] Putty - transparent "eye-candy" patch
Fri, 22 Jun 2018 15:00:08 +0200 [16] Nutty – SSH Client for Windows
Fri, 22 Jun 2018 15:02:18 +0200 [17] ExtraPuTTY | Fork of PuTTY
Sun, 24 Jun 2018 15:15:52 +0200 [18] PuTTY Team Members
Sun, 24 Jun 2018 19:49:00 +0200 [19] Support ssh:// URI · Issue #203 · FauxFaux/PuTTYTray
Sun, 24 Jun 2018 19:57:24 +0200 [20] Other forks of PuTTY · FauxFaux/PuTTYTray Wiki
Sun, 24 Jun 2018 21:19:05 +0200 [21] iceiv+putty
Mon, 25 Jun 2018 14:59:14 +0200 [22] ReGIS - Wikipedia
Mon, 25 Jun 2018 14:59:15 +0200 [23] Sixel - Wikipedia
Fri, 27 Aug 2021 18:42:02 +0200 [24] ShellExecuteA function (shellapi.h) - Win32 apps | Microsoft Docs
Mon, 30 Jan 2023 16:49:06 +0100 [25] PuTTY bug win-jumplist-trouble
Mon, 30 Jan 2023 16:55:44 +0100 [26] win32/appids.md at docs · MicrosoftDocs/win32
Fri, 17 May 2024 15:06:16 +0200 [27] KiTTY, a free telnet/ssh client for Windows

Back to top