Aseguráte de tener estos paquetes instalados en tu computadora
- Instalar git
- Terminal y ambiente de terminal: Git bash, bash o powershell (windows)
- Crear una cuenta en hub.docker.com
- Crear una cuenta en github.com si no la tiene creada
Aseguráte de tener estos paquetes instalados en tu computadora
| /* debug.css | MIT License | zaydek.github.com/debug.css */ if (!("is_debugging" in window)) { is_debugging = false; var debug_el = document.createElement("style"); debug_el.append(document.createTextNode(`*:not(g):not(path) { color: hsla(210, 100%, 100%, 0.9) !important; background: hsla(210, 100%, 50%, 0.5) !important; outline: solid 0.25rem hsla(210, 100%, 100%, 0.5) !important; box-shadow: none !important; filter: none !important; }`)); } function enable_debugger() { if (!is_debugging) { document.head.appendChild(debug_el); is_debugging = true; } } function disable_debugger() { if (is_debugging) { document.head.removeChild(debug_el); is_debugging = false; } } !is_debugging ? enable_debugger() : disable_debugger(); |
| function parseJwt (token) { | |
| var base64Url = token.split('.')[1]; | |
| var base64 = base64Url.replace('-', '+').replace('_', '/'); | |
| return JSON.parse(window.atob(base64)); | |
| }; |
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
| Install i3-gaps on Ubuntu 16 | |
| apt-get install libxcb1-dev libxcb-keysyms1-dev libpango1.0-dev libxcb-util0-dev libxcb-icccm4-dev libyajl-dev libstartup-notification0-dev libxcb-randr0-dev libev-dev libxcb-cursor-dev libxcb-xinerama0-dev libxcb-xkb-dev libxkbcommon-dev libxkbcommon-x11-dev autoconf xutils-dev dh-autoreconf | |
| git clone --recursive https://github.com/Airblader/xcb-util-xrm.git | |
| cd xcb-util-xrm/ | |
| ./autogen.sh | |
| make | |
| sudo make install |
| /** | |
| * Generates a MongoDB-style ObjectId in Node.js. Uses nanosecond timestamp in place of counter; | |
| * should be impossible for same process to generate multiple objectId in same nanosecond? (clock | |
| * drift can result in an *extremely* remote possibility of id conflicts). | |
| * | |
| * @returns {string} Id in same format as MongoDB ObjectId. | |
| */ | |
| function objectId() { | |
| const os = require('os'); | |
| const crypto = require('crypto'); |
Sometimes you may want to undo a whole commit with all changes. Instead of going through all the changes manually, you can simply tell git to revert a commit, which does not even have to be the last one. Reverting a commit means to create a new commit that undoes all changes that were made in the bad commit. Just like above, the bad commit remains there, but it no longer affects the the current master and any future commits on top of it.
git revert {commit_id}
Deleting the last commit is the easiest case. Let's say we have a remote origin with branch master that currently points to commit dd61ab32. We want to remove the top commit. Translated to git terminology, we want to force the master branch of the origin remote repository to the parent of dd61ab32:
| <?php | |
| // Source: http://stackoverflow.com/questions/5943368/dynamically-generating-a-qr-code-with-php | |
| // Google Charts Documentation: https://developers.google.com/chart/infographics/docs/qr_codes?csw=1#overview | |
| // CHart Type | |
| $cht = "qr"; | |
| // CHart Size | |
| $chs = "300x300"; |