[WayBack] Dieses sudo-Gehampel unter Debian/Ubuntu nervt. Aber es gibt Abhilfe: alias iddqd=’sudo su -‘ – Kristian Köhntopp – Google+
Or maybe this:
iddqd='sudo -i'
–jeroen
Posted by jpluimers on 2018/12/24
[WayBack] Dieses sudo-Gehampel unter Debian/Ubuntu nervt. Aber es gibt Abhilfe: alias iddqd=’sudo su -‘ – Kristian Köhntopp – Google+
Or maybe this:
iddqd='sudo -i'
–jeroen
Posted in *nix, Linux, Power User | Leave a Comment »
Posted by jpluimers on 2018/12/24
From a while back, but still so cool! It allows you to “recover” the terminal (stdin/stdout/stderr) of a process that was attached to a terminal or ssh session.
Reptyr – Forgot to “screen” your ssh session first, and now that long running thing is stuck?
»
reptyr PIDwill grab the process with id PID and attach it to your current terminal.«server:~ # zypper install reptyr ... Retrieving: reptyr-0.3dev_git20120325-7.1.2.x86_64.rpm ...................[done] (1/1) Installing: reptyr-0.3dev_git20120325-7.1.2 ........................[done] server:~ # rpm -qi reptyr ... Summary : A tool for "re-ptying" programs Description : reptyr is a utility for taking an existing running program and attaching it to a new terminal. Started a long-running process over ssh, but have to leave and don't want to interrupt it? Just start a screen, use reptyr to grab it, and then kill the ssh session and head on home. Distribution: openSUSE 13.1
Source: [WayBack] Reptyr – Forgot to “screen” your ssh session first, and now that long running thing is stuck?… – Kristian Köhntopp – Google+
It works with tmux too and is supported on many Linux distributions, see for instance [WayBack] Reptyr – Move A Running Process From One Terminal To Another Without Closing It – OSTechNix.
You can even redirect a pty for gdb usage: [WayBack] reptyr(1): new terminal – Linux man page
StackExchange thread: [WayBack] How to recover a shell after a disconnection with these entries:
Originally from 2011 [WayBack] reptyr: Attach a running process to a new terminal – Made of Bugs it is still maintained:
GitHub repository [WayBack] nelhage/reptyr: Reparent a running program to a new terminal
–jeroen
Posted in *nix, *nix-tools, Linux, openSuSE, Power User, screen, SuSE Linux, tmux | Leave a Comment »
Posted by jpluimers on 2018/12/21
Be careful what you do: blindly following Super User can make sudo unavailable: [WayBack] linux – Keeping the fancy sudo warning forever – Super User.
Following the answer archived in the WayBack machine gets you into this situation:
sudo -i
>>> /etc/sudoers.d/privacy: syntax error near line 1 <<<
sudo: parse error in /etc/sudoers.d/privacy near line 1
sudo: no valid sudoers sources found, quitting
sudo: unable to initialize policy plugin
The cause:
I forgot to put a line terminator at the end of the line in the privacy file.
If you do that, then it works fine: add this line INCLUDING A LINE TERMINATOR to /etc/sudoers.d/privacy (any file in that directory will do):
Default lecture=always
The first time I do
sudoon openSUSE I’m always warned with a someway fancy messageWe trust you have received the usual lecture from the local System Administrator. It usually boils down to these three things: #1) Respect the privacy of others. #2) Think before you type. #3) With great power comes great responsibility. root's password:After the first successful login I won’t be warned again.
I’d like to be always warned. I find this message someway fancy. Is there any way to be warned like that by sudo prompt?
Happily, however, my
man sudoersadmits of the stringlecture_filewhich it says is the[p]ath to a file containing an alternate sudo lecture that will be used in place of the standard lecture if the named file exists. By default, sudo uses a built-in lecture.
So see if your sudo supports that, and if it does, set it to a particular filename with e.g.
Defaults lecture_file = /etc/sudoers.lectureand put your lecture text in that file. You may find this easier to test, as I did, if you also do
Defaults lecture = alwayswhich will display the lecture on every invocation of sudo. Otherwise you may run out of accounts which have never sudo’ed while you get this right!
–jeroen
Posted in *nix, *nix-tools, Power User | Leave a Comment »
Posted by jpluimers on 2018/12/21
Is there a URL query string for searching own GitHub Gists? – Stack Overflow.
Yes, there is, and search terms search within your gists too:
user:jpluimersuser:jpluimers tripledigitsMore search parameters are at https://github.com/random-parts/til/blob/master/github/gist-search-cheatsheet.md
–jeroen
Posted in Development, DVCS - Distributed Version Control, gist, git, GitHub, Power User, Source Code Management | Leave a Comment »
Posted by jpluimers on 2018/12/21
Steps:
You can use example search shortcuts from Forcing Chrome to use google.com as search engine.
If you forget the first step, then often your search still will go a localised place (except when you are in the USA).
–jeroen
Posted in Google, GoogleSearch, Power User | Leave a Comment »
Posted by jpluimers on 2018/12/21
I missed this earlier this year, but while switching phones found out: Google Now is not available for most devices any more.
So I’ am looking for a replacement that has:
This I totally missed:
–jeroen
Posted in Android Devices, LifeHacker, Power User | Leave a Comment »
Posted by jpluimers on 2018/12/20
The Delphi IDE manages the .dpr and .dproj files for, trying to keep them in sync.
Some information is duplicated between the two, especially files referenced by relative paths: those files are contained in your project.
This means you cannot do something like this in your .dpr file:
{$IFDEF DEBUG}
Debug in '..\..\..\..\Shared\Debug.pas';
{$ELSE}
Debug in '..\Debug.pas'
{$ENDIF}
There is no equivalent for this in the .dproj and it will confuse the IDE which file now actually is or is not inside your project.
Better to leave the file outside of your project, then modify the RELEASE/DEBUG search paths to have the correct one.
Even better is to have just one Debug.pas file containing the changes.
–jeroen
Posted in Conference Topics, Conferences, Delphi, Development, Event, Software Development | Leave a Comment »
Posted by jpluimers on 2018/12/20
[WayBack] About Blocks – bl.ocks.org is so cool:
Bl.ocks (pronounced “Blocks”) is a simple viewer for sharing code examples hosted on GitHub Gist.
…
The main source for your example is in
index.html. This file can contain relative links to other files in your Gist, such as images, scripts or stylesheets. And of course you can use absolute links, such as CDN-hosted D3, jQuery or Leaflet. To explain your example, add aREADME.mdwritten in Markdown. (You can omit theindex.htmlif you just want to write, too.)
[WayBack] Code-only-Blocks are cool too:
When your Gist is missing an
index.htmlfile, will hide the example iframe but continue to display everything else.
Just compare these:
–jeroen
Posted in Development, DVCS - Distributed Version Control, gist, GitHub, jQuery, Scripting, Software Development, Source Code Management, Web Development | Leave a Comment »
Posted by jpluimers on 2018/12/20
Lovely: people that perform incomplete Firebird deployments…
This means the firebird.msg file on the client is either not found or is a different version than the server.
Source: [WayBack] Can’t format message nn:mmm — message text not found
–jeroen
Posted in Database Development, Development, Firebird | Leave a Comment »