In your command-line run the following commands:
brew doctor
brew update
// origin: https://gist.github.com/tomhicks/6cb5e827723c4eaef638bf9f7686d2d8 , tomhicks/plink-plonk.js | |
/* | |
Copy this into the console of any web page that is interactive and doesn't | |
do hard reloads. You will hear your DOM changes as different pitches of | |
audio. | |
I have found this interesting for debugging, but also fun to hear web pages | |
render like UIs do in movies. | |
*/ |
/* | |
Copy this into the console of any web page that is interactive and doesn't | |
do hard reloads. You will hear your DOM changes as different pitches of | |
audio. | |
I have found this interesting for debugging, but also fun to hear web pages | |
render like UIs do in movies. | |
*/ | |
const audioCtx = new (window.AudioContext || window.webkitAudioContext)() |
import {NgModule} from '@angular/core'; | |
import {HomeComponent} from './home/home.component'; | |
import {AboutUsComponent} from './about-us/about-us.component'; | |
import {ContactComponent} from './contact/contact.component'; | |
import {UIRouterUpgradeModule} from "@uirouter/angular-hybrid"; | |
export const StaticPagesRoutes = { | |
states: [ | |
{ | |
name: 'home', |
import {NgModule} from '@angular/core'; | |
import {HomeComponent} from './home/home.component'; | |
import {AboutUsComponent} from './about-us/about-us.component'; | |
import {ContactComponent} from './contact/contact.component'; | |
export class DependencyInjectionClass { | |
constructor(private _service: FictionalService) {} | |
resolve(route, state) { | |
//Get some fictional data with the id that's in the URL |
import { Injectable } from '@angular/core'; | |
import { environment } from '../../../environments/environment'; | |
export interface ILoggerService { | |
info(value: any, ...rest: any[]): void; | |
log(value: any, ...rest: any[]): void; | |
warn(value: any, ...rest: any[]): void; | |
error(value: any, ...rest: any[]): void; | |
} |
Just a minimal CARTO.js example with the defalut Leaflet Control Geocoder.
Simply add the JS and CSS imports
<!-- Geocoder-->
<link rel="stylesheet" href="https://unpkg.com/leaflet-control-geocoder/dist/Control.Geocoder.css" />
<script src="https://unpkg.com/leaflet-control-geocoder/dist/Control.Geocoder.js"></script>
export ZSH=$HOME/.oh-my-zsh | |
export DEFAULT_USER='athityakumar' | |
TERM=xterm-256color | |
ZSH_THEME="powerlevel9k/powerlevel9k" | |
POWERLEVEL9K_MODE='awesome-fontconfig' | |
POWERLEVEL9K_PROMPT_ON_NEWLINE=true | |
POWERLEVEL9K_PROMPT_ADD_NEWLINE=true | |
POWERLEVEL9K_RPROMPT_ON_NEWLINE=true | |
POWERLEVEL9K_SHORTEN_DIR_LENGTH=2 |
The connection failed because by default psql
connects over UNIX sockets using peer
authentication, that requires the current UNIX user to have the same user name as psql
. So you will have to create the UNIX user postgres
and then login as postgres
or use sudo -u postgres psql database-name
for accessing the database (and psql
should not ask for a password).
If you cannot or do not want to create the UNIX user, like if you just want to connect to your database for ad hoc queries, forcing a socket connection using psql --host=localhost --dbname=database-name --username=postgres
(as pointed out by @meyerson answer) will solve your immediate problem.
But if you intend to force password authentication over Unix sockets instead of the peer method, try changing the following pg_hba.conf
* line:
from