-
macOS Mojave Slow? Fixes Here – Techsviewer
” Go to “System preferences” the click on “Accessibility”
2. Click on “Display” and check the box next to “Reduce transparency” and “Reduce Motion”.”-
on “System Preferences”.
3. Click on “Desktop and screen savers”.
4. Select the wallpaper you want and set it.
-
-
django – Pytz – timezone activated yet getting wrong time. Am I missing something? – Stack Overflow
“import pytz
from django.utils import timezone”
timezone.activate(pytz.timezone(tz_str))
-
timezone.activate(pytz.timezone(tz_str))
-
Mês: julho 2018
Update (weekly)
-
Python Tutorial: Exception Handling
“whereas in Java exceptions are caught by catch clauses, we have statements introduced by an “except” keyword in Python. “
-
How to install Windows 7 on systems with Skylake chipset | Dell Brasil
“modify the image”
-
postgresql – How connect Postgres to localhost server using pgAdmin on Ubuntu? – Stack Overflow
“1. Open the file pg_hba.conf
sudo nano /etc/postgresql/9.x/main/pg_hba.confand change this line:
Database administrative login by Unix domain socket
local all postgres md5
toDatabase administrative login by Unix domain socket
local all postgres trust
Restart the serversudo service postgresql restart
Login into psql and set password
psql -U postgres
ALTER USER postgres with password ‘new password’;
Again open the file pg_hba.conf and change this line:
Database administrative login by Unix domain socket
local all postgres trust
toDatabase administrative login by Unix domain socket
local all postgres md5
Restart the server
sudo service postgresql restartIt works.”
Update (weekly)
-
“My sollution was to reduce the timeout, and to do so without messing with the base installed networking.services systemd file. This will persist during updates in any package.
sudo mkdir -p /etc/systemd/system/networking.service.d/
sudo bash -c ‘echo -e “[Service]\nTimeoutStartSec=20sec” > /etc/systemd/system/networking.service.d/timeout.conf’
sudo systemctl daemon-reload” -
[ubuntu] A start job is running for raise network interfaces (5 mins 1 sec) in ubuntu16.04
“systemctl status systemd-networkd-wait-online.service
Code:
systemctl status NetworkManager-wait-online.service
Disable one and, if it does not fix it, re-enable it and disable the other one.Here’s an example
Code:
sudo systemctl disable systemd-networkd-wait-online.service
Code:
sudo systemctl enable systemd-networkd-wait-online.service” -
Migrate pg dump from Heroku to local sqlite3 development (and beyond)
“heroku pgbackups:capture
curl -o latest.dump `heroku pgbackups:url`# Install postregs & Setup password
# https://help.ubuntu.com/community/PostgreSQL# List databases
sudo -u postgres psql -l# Create database for data
# http://www.commandprompt.com/ppbook/x17149
sudo -u postgres psql template1
template1=# CREATE DATABASE bikedb# or
sudo -u postgres createdb bikedb# Run restore script with options
# http://antonzolotov.com/2012/03/04/rails-scripts-clone-heroku-database-to-development.html
sudo -u postgres pg_restore –verbose –clean –no-acl –no-owner -h localhost -d bikedb latest.dump” -
postgresql – pg_restore asking for password for database when there isn’t one – Stack Overflow
“If you’re specifying -h localhost explicitly then you’re using TCP/IP, so you’ll need to either omit -h localhost”
Update (weekly)
-
What is the best free GUI PostgreSQL client for macOS? – Quora
“Valentina Studio is free and available on the Mac OS X platform.
I can’t help but notice many answers here are for products that don’t have a free version. Valentina Studio is easy to use, and is regularly updated on a regular basis. It is also available through the Mac App Store”
-
“hostname=XXX port=443 trust_cert_file_location=`curl-config –ca` sudo bash -c “echo -n | openssl s_client -showcerts -connect $hostname:$port \ 2>/dev/null | sed -ne ‘/-BEGIN CERTIFICATE-/,/-END CERTIFICATE-/p’ \ >> $trust_cert_file_location””
-
Clonezilla Clone Larger Disk to Smaller Disk-Workaround
“Choose EXPERT mode and enable the “-icds” option”
-
How to Rearrange and Remove Your Mac’s Menu Bar Icons
“To move any menu bar icon, simply hold the “Command” key, then click and drag the icon. You can move any icon anywhere this way”