docker-compose exec -u postgres postgres pg_dumpall -c > prod_`date +%d-%m-%Y"_"%H_%M_%S`.sql
docker-compose exec -u postgres postgres pg_dump -d "DATABASE" -t 'TABLE' > TABLE_`date +%d-%m-%Y"_"%H_%M_%S`.sql
var ip = "http://localhost" | |
var dbName = "DB_NAME" | |
var viewType = "VIEW_TYPE" | |
var viewName = "VIEW_NAME" | |
$.getJSON(ip+":5984/"+dbName+"/_design/"+viewType+"/_view/"+viewName+"/", function(data) { | |
data.rows.forEach(function (doc) { | |
$.ajax({ | |
url: ip+":5984/"+dbName+"/" + doc.value._id + '?rev=' + doc.value._rev, | |
type: 'DELETE', | |
success: function(result) { |
var ip = "localhost" | |
var dbName = "DBNAME" | |
var viewType = "VIEWTYPE" | |
var viewName = "VIEWNAME" | |
$.getJSON("http://"+ip+":5984/"+dbName+"/_design/"+viewType+"/_view/"+viewName+"/", function(data) { | |
data.rows.forEach(function (doc) { | |
var __id = doc.value._id | |
delete doc.value._id | |
var newDoc = doc.value | |
newDoc.values = Object.assign({}, doc.value.values, {newValue: false}) |
(function(){ | |
var blob=new Blob([$0.outerHTML]); | |
var link=document.createElement('a'); | |
link.href=window.URL.createObjectURL(blob); | |
link.download="myFileName.txt"; | |
link.click(); | |
})() |
<script> | |
(function() { | |
var a = console.log; | |
var b = console.error; | |
var c = console.info; | |
var d = fetch; | |
var output = document.createElement("div"); | |
output.style.cssText = | |
"position:fixed; background: white; width: 50vw; height: 100vh; z-index: 99; right: 0; top: 0; overflow: auto; word-wrap: pre-wrap;"; | |
document.body.appendChild(output); |
## Tizen configuration | |
1. Download Tizen CLI from here https://developer.tizen.org/development/tizen-studio/download | |
2. `chmod 755 web-cli_Tizen_Studio_3.7_ubuntu-64.bin` | |
3. `~/tizen-studio/tools/ide/bin/tizen certificate -a ProfileName -p 1234 -f profile_filename` | |
4. `~/tizen-studio/tools/ide/bin/tizen security-profiles add -n ProfileName -a ~/tizen-studio-data/keystore/author/profile_filename.p12 -p 1234` | |
5. Edit `~/tizen-studio-data/profile/profiles.xml` and change password fields like this: | |
``` | |
<profileitem ...profile_filename.p12" password="" rootca=""/> | |
<profileitem ...tizen-distributor-signer.p12" password="tizenpkcs12passfordsigner" rootca=""/> |
Here we can see the alternative solutions to prevent request URI too long / large (414 code)