This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// para insertar fecha en campo textfield | |
new java.text.SimpleDateFormat("dd-MMM-yyyy HH:mm:ss z", java.util.Locale.US).format(new java.util.Date()) | |
// para mostrar fecha en español | |
new Locale("ES") | |
// usando groovy | |
new groovy.lang.GroovyShell().evaluate("Calendar cal = Calendar.getInstance(); cal.set(2009, 8, 8); return cal.getTime(); ") | |
 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
turns out you don't need the bind mount. This works with current docker by just modifying the -g option in /etc/docker/defaults DOCKER_OPTS. I had previously tried this and maybe like you failed to get it to work, and looked to linking and bind mounting. | |
Tried on AWS EC2 VM on a Ubuntu 14.04 server, with a second block storage volume. | |
First prepare your new block storage, this will house the moved docker folder | |
First format and mount the new block storage device | |
mkfs.ext4 /dev/sdx | |
Mount it | |
create a mount point | |
mkdir /mnt/diskX |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package primertarea; | |
/** | |
* | |
* @author Jonathan Miranda | |
*/ | |
public class Calculadora { | |
public static int agregar(String nums) { | |
int total = 0; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(gdb) disassemble | |
Dump of assembler code for function _start: | |
0x00000000004000b0 <+0>: mov eax,0x4 | |
0x00000000004000b5 <+5>: mov ebx,0x1 | |
0x00000000004000ba <+10>: mov ecx,0x6000d4 | |
0x00000000004000bf <+15>: mov edx,0x26 | |
0x00000000004000c4 <+20>: int 0x80 | |
0x00000000004000c6 <+22>: mov eax,0x1 | |
=> 0x00000000004000cb <+27>: mov ebx,0x6 | |
0x00000000004000d0 <+32>: int 0x80 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
update ir_module_module set state='installed' where='to upgrade' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
NR_JAR=/usr/share/tomcat/newrelic/newrelic.jar; export NR_JAR | |
JAVA_OPTS="$JAVA_OPTS -javaagent:$NR_JAR \ | |
-Dcom.sun.management.jmxremote=true \ | |
-Dcom.sun.management.jmxremote.port=9696 \ | |
-Dcom.sun.management.jmxremote.ssl=false \ | |
-Dcom.sun.management.jmxremote.authenticate=false \ | |
-Djava.rmi.server.hostname=[ip]"; export JAVA_OPTS |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[options] | |
; This is the password that allows database operations | |
admin_passwd = admin | |
db_host = false | |
db_port = false | |
db_user = odoo | |
db_password = false | |
addons_path=/opt/odoo/v8/other-addons,/opt/odoo/v8/core/addons,/opt/odoo/v8/core/openerp/addons | |
;logfile = /var/log/odoo/odoo-server.log | |
xmlrpc_port = 8072 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[options] ; | |
This is the password that allows database operations: ; | |
admin_passwd = admin | |
db_host = False | |
db_port = False | |
db_user = openerp | |
db_password = False | |
addons_path=/opt/openerp/server/addons | |
;logfile = /var/log/openerp/openerp-server.log | |
xmlrpc_port = 8069 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
config.vm.provision :chef_solo do |chef| | |
chef.cookbooks_path = "cookbooks" | |
chef.log_level = "debug" | |
chef.add_recipe "odoo" | |
#chef.json = { | |
# :postgresql => { | |
# :version => "9.3", | |
# :listen_address => "*", | |
# :hba => [ | |
# { :method => "trust", :address => "0.0.0.0/0"}, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public static String getNumDia(String fecha) { | |
Calendar c = Calendar.getInstance(); | |
try { | |
SimpleDateFormat sm = new SimpleDateFormat("dd/MM/yyyy"); | |
c.setTime(sm.parse(fecha)); | |
return String.valueOf(c.get(5)); | |
} catch (ParseException ex) { | |
GenericsUtils.sendExceptionToLogger("sae.pb", ex); | |
} | |
return ""; |