I hereby claim:
- I am trumbitta on github.
- I am trumbitta (https://keybase.io/trumbitta) on keybase.
- I have a public key ASARmoiH9925VGV05nOcxWzEt_U9i84paZE99gp0Pnil3Ao
To claim this, I am signing this object:
| export class HttpErrorInterceptor implements HttpInterceptor { | |
| intercept(request: HttpRequest<any>, next: HttpHandler): Observable<HttpEvent<any>> { | |
| return next.handle(request).pipe( | |
| tap( | |
| () => {}, | |
| error => { | |
| // There may be other events besides the response error. | |
| if ( | |
| error instanceof HttpErrorResponse | |
| ) { |
| # Based on https://github.com/robbyrussell/oh-my-zsh/blob/master/themes/dpoggi.zsh-theme | |
| # set newline variable to be used in the prompt | |
| NEWLINE=$'\n' | |
| if [ $UID -eq 0 ]; then NCOLOR=001; else NCOLOR=254; fi | |
| local return_code="%(?..%{$fg[red]%}%? ↵%{$reset_color%})" | |
| PROMPT='%{$FG[$NCOLOR]%}%n%{$reset_color%}@%m\ | |
| :%~\ |
| function withLatestFromSelector<A, R, S, I>( | |
| state$: StateObservable<A>, | |
| selector: OutputSelector<A, R, S>, | |
| ): OperatorFunction<I, Array<I | R>> { | |
| return (input$) => | |
| input$.pipe( | |
| withLatestFrom(state$), | |
| map(([input, state]) => [input, selector(state)]), | |
| ); | |
| } |
| (function () { | |
| for (const text of document.querySelectorAll("[data-testid='tweet'] div:nth-child(2) > div:nth-child(2) > div:nth-child(2) > div > span")) { | |
| if (text.textContent) { | |
| text.textContent = "IMHO, " + text.textContent; | |
| } | |
| } | |
| })() |
| # Enable Powerlevel10k instant prompt. Should stay close to the top of ~/.zshrc. | |
| # Initialization code that may require console input (password prompts, [y/n] | |
| # confirmations, etc.) must go above this block; everything else may go below. | |
| if [[ -r "${XDG_CACHE_HOME:-$HOME/.cache}/p10k-instant-prompt-${(%):-%n}.zsh" ]]; then | |
| source "${XDG_CACHE_HOME:-$HOME/.cache}/p10k-instant-prompt-${(%):-%n}.zsh" | |
| fi | |
| # If you come from bash you might have to change your $PATH. | |
| # export PATH=$HOME/bin:/usr/local/bin:$PATH |
I hereby claim:
To claim this, I am signing this object: