<?xml version='1.0' encoding='UTF-8'?><?xml-stylesheet href="http://www.blogger.com/styles/atom.css" type="text/css"?><feed xmlns='http://www.w3.org/2005/Atom' xmlns:openSearch='http://a9.com/-/spec/opensearchrss/1.0/' xmlns:blogger='http://schemas.google.com/blogger/2008' xmlns:georss='http://www.georss.org/georss' xmlns:gd="http://schemas.google.com/g/2005" xmlns:thr='http://purl.org/syndication/thread/1.0'><id>tag:blogger.com,1999:blog-1657736901030895703</id><updated>2024-10-24T13:33:51.153-03:00</updated><category term="linux"/><category term="consola"/><category term="debian"/><category term="windows"/><category term="mysql"/><category term="archlinux"/><category term="pentaho"/><category term="cli"/><category term="latex"/><category term="centos"/><category term="USM"/><category term="bash"/><category term="SQL"/><category term="bi"/><category term="matematicas"/><category term="ruby"/><category term="sqlserver"/><category term="windows xp"/><category term="code"/><category term="mat021"/><category term="megaupload"/><category term="mondrian"/><category term="openreport"/><category term="red"/><category term="schema workbench"/><category term="DOS"/><category term="ari"/><category term="lenguaje c"/><category term="opensource"/><category term="programacion"/><category term="utfsm"/><category term="windows 7"/><category term="xmms"/><category term="charlas"/><category term="configuracion"/><category term="console"/><category term="gnome"/><category term="info"/><category term="java"/><category term="programing"/><category term="rapidshare"/><category term="tomcat"/><category term="wget"/><category term="zip"/><category term="7z"/><category term="CRM"/><category term="MDX"/><category term="Oracle"/><category term="Python"/><category term="Splunk"/><category term="Terminal"/><category term="ajedrez"/><category term="algoritmo"/><category term="amazon"/><category term="android"/><category term="base64"/><category term="c"/><category term="cakephp"/><category term="debin"/><category term="descomprimir"/><category term="download"/><category term="electronica"/><category term="etl"/><category term="gestor"/><category term="hardware"/><category term="iceweasel"/><category term="infobright"/><category term="ip"/><category term="javascript"/><category term="jpivot"/><category term="js"/><category term="juegos"/><category term="kde"/><category term="lenny"/><category term="links"/><category term="mac"/><category term="mat022"/><category term="mplayer"/><category term="negocios"/><category term="notebooks"/><category term="oldschool"/><category term="openi"/><category term="openvpn"/><category term="opinión"/><category term="otros"/><category term="php"/><category term="plowshare"/><category term="postgresql"/><category term="problema"/><category term="productos"/><category term="s3"/><category term="script"/><category term="tmux"/><category term="twitter"/><category term="ubuntu"/><category term="wdtv"/><category term="winamp"/><category term="windows.ssis"/><title type='text'>Code &amp;amp; Stuffs</title><subtitle type='html'>Problems, Tips &amp;amp; Tricks</subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://pintoland.blogspot.com/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1657736901030895703/posts/default?redirect=false'/><link rel='alternate' type='text/html' href='http://pintoland.blogspot.com/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><link rel='next' type='application/atom+xml' href='http://www.blogger.com/feeds/1657736901030895703/posts/default?start-index=26&amp;max-results=25&amp;redirect=false'/><author><name>Fabián Pinto</name><uri>http://www.blogger.com/profile/03020316804062827481</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjjBT1cIyxpb3rWvPknQdrqXFPxQKVpc6Wre53OWSYByRw5C8IWvRHX3_B0IkuXPkZ8XKqCf3SoCac-wcQkZrrftE1jQyXHTM-wPddFglilI2iJIbYidRqLpPTKbqyAHIJhe8Xw37NL-iIXYUUxKnQy-pNrjV6LdRfwKW-_xaIKF6o/s220/321233897_3296355443911743_3463809348725319721_n.jpg'/></author><generator version='7.00' uri='http://www.blogger.com'>Blogger</generator><openSearch:totalResults>202</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>25</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-1657736901030895703.post-7576901754414680371</id><published>2023-02-20T03:39:00.000-03:00</published><updated>2023-02-20T03:39:17.740-03:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="Oracle"/><category scheme="http://www.blogger.com/atom/ns#" term="SQL"/><title type='text'>How to remove a trailing comma at the end of a string in Oracle</title><content type='html'>So I&#39;m working in a database and  in a particular column there is a trailing comma that I need to remove, a simple solution is something like this:

We have something like this
&lt;pre&gt;&lt;code class=&quot;brush:sql&quot;&gt;
SELECT &#39;a, b, c, d,&#39; test From  dual;
&lt;/code&gt;&lt;/pre&gt;
The output is:
&lt;pre&gt;&lt;code class=&quot;language-plaintext&quot;&gt;
a, b, c, d,
&lt;/code&gt;&lt;/pre&gt;
To clean the last comma we can use &lt;code&gt;RTRIM&lt;/code&gt;
&lt;pre&gt;&lt;code class=&quot;brush:sql&quot;&gt;
SELECT RTRIM(&#39;a, b, c, d,&#39;, &#39;,&#39;) new_test From  dual;
&lt;/code&gt;&lt;/pre&gt;
The output is:
&lt;pre&gt;&lt;code class=&quot;language-plaintext&quot;&gt;
a, b, c, d
&lt;/code&gt;&lt;/pre&gt;

Pretty neat!!!!
&lt;a href=&quot;https://www.techonthenet.com/oracle/functions/rtrim.php&quot; target=&quot;_blank&quot;&gt;RTRIM function&lt;/a&gt;
&lt;a href=&quot;https://community.spiceworks.com/topic/2391226-sqr-how-to-remove-a-comma-at-the-end-of-a-string&quot; target=&quot;_blank&quot;&gt;Source 2&lt;/a&gt;</content><link rel='replies' type='application/atom+xml' href='http://pintoland.blogspot.com/feeds/7576901754414680371/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/1657736901030895703/7576901754414680371' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1657736901030895703/posts/default/7576901754414680371'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1657736901030895703/posts/default/7576901754414680371'/><link rel='alternate' type='text/html' href='http://pintoland.blogspot.com/2023/02/how-to-remove-trailing-comma-at-end-of.html' title='How to remove a trailing comma at the end of a string in Oracle'/><author><name>Fabián Pinto</name><uri>http://www.blogger.com/profile/03020316804062827481</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjjBT1cIyxpb3rWvPknQdrqXFPxQKVpc6Wre53OWSYByRw5C8IWvRHX3_B0IkuXPkZ8XKqCf3SoCac-wcQkZrrftE1jQyXHTM-wPddFglilI2iJIbYidRqLpPTKbqyAHIJhe8Xw37NL-iIXYUUxKnQy-pNrjV6LdRfwKW-_xaIKF6o/s220/321233897_3296355443911743_3463809348725319721_n.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1657736901030895703.post-1677680457404894939</id><published>2023-02-19T01:40:00.005-03:00</published><updated>2023-02-20T03:40:36.332-03:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="pentaho"/><category scheme="http://www.blogger.com/atom/ns#" term="SQL"/><title type='text'>Trying to connect to oracle with Pentaho Ketlle and failed</title><content type='html'>So I was trying to connect to a Oracle database when I got this error&lt;br /&gt;
&lt;br /&gt;
&lt;pre&gt;&lt;code class=&quot;language-plaintext&quot;&gt;
Connection failed. Verify all connection parameters and confirm that the appropriate driver is installed.
Listener refused the connection with the following error:
ORA-12505, TNS:listener does not currently know of SID given in connect descriptor
 &lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;
The configuration for the connection that I have is using the &quot;Service Name&quot; so in this case is an easy fix, just put a &quot;/&quot; in the beginning
, like this.&lt;br /&gt; 
&lt;div class=&quot;separator&quot; style=&quot;clear: both;&quot;&gt;&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEix-Vji7_aHLY9-Ge1X6CukiLRkndAbujl-JcvY49NAI0wAwOdT_QMG9ZSFQdjd0zSZeW2xwT0A_U4jSSFZwA1w7f-_ZjZmdo5pz9OGFhC6THV4cZpD6XzLkFfuKtswPABe5LS0cxnRwhsuywMokbrl72De5RjvpQebiU39V8fAp4TKc2PqWvDAuY7q/s671/eo.png&quot; style=&quot;display: block; padding: 1em 0; text-align: center; clear: left; float: left;&quot;&gt;&lt;img alt=&quot;&quot; border=&quot;0&quot; width=&quot;320&quot; data-original-height=&quot;233&quot; data-original-width=&quot;671&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEix-Vji7_aHLY9-Ge1X6CukiLRkndAbujl-JcvY49NAI0wAwOdT_QMG9ZSFQdjd0zSZeW2xwT0A_U4jSSFZwA1w7f-_ZjZmdo5pz9OGFhC6THV4cZpD6XzLkFfuKtswPABe5LS0cxnRwhsuywMokbrl72De5RjvpQebiU39V8fAp4TKc2PqWvDAuY7q/s320/eo.png&quot;/&gt;&lt;/a&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pintoland.blogspot.com/feeds/1677680457404894939/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/1657736901030895703/1677680457404894939' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1657736901030895703/posts/default/1677680457404894939'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1657736901030895703/posts/default/1677680457404894939'/><link rel='alternate' type='text/html' href='http://pintoland.blogspot.com/2018/11/trying-to-connect-to-oracle-with.html' title='Trying to connect to oracle with Pentaho Ketlle and failed'/><author><name>Fabián Pinto</name><uri>http://www.blogger.com/profile/03020316804062827481</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjjBT1cIyxpb3rWvPknQdrqXFPxQKVpc6Wre53OWSYByRw5C8IWvRHX3_B0IkuXPkZ8XKqCf3SoCac-wcQkZrrftE1jQyXHTM-wPddFglilI2iJIbYidRqLpPTKbqyAHIJhe8Xw37NL-iIXYUUxKnQy-pNrjV6LdRfwKW-_xaIKF6o/s220/321233897_3296355443911743_3463809348725319721_n.jpg'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEix-Vji7_aHLY9-Ge1X6CukiLRkndAbujl-JcvY49NAI0wAwOdT_QMG9ZSFQdjd0zSZeW2xwT0A_U4jSSFZwA1w7f-_ZjZmdo5pz9OGFhC6THV4cZpD6XzLkFfuKtswPABe5LS0cxnRwhsuywMokbrl72De5RjvpQebiU39V8fAp4TKc2PqWvDAuY7q/s72-c/eo.png" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1657736901030895703.post-4397974396270063513</id><published>2022-08-25T01:32:00.002-04:00</published><updated>2022-08-25T01:40:05.834-04:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="bash"/><category scheme="http://www.blogger.com/atom/ns#" term="cli"/><category scheme="http://www.blogger.com/atom/ns#" term="linux"/><title type='text'>Check ports if we don&#39;t have access to Telnet</title><content type='html'>In a project I&#39;m helping sometimes as the support guy,so in the machine that I was working isn&#39;t posible to install anything and &lt;code&gt;Telnet&lt;/code&gt; wasn&#39;t installed, one solution is using &lt;code&gt;curl&lt;/code&gt;.&lt;/br&gt;

&lt;h3&gt;&lt;p&gt;Command Line&lt;/p&gt;&lt;/h3&gt;
&lt;pre&gt;&lt;code class=&quot;brush:bash&quot;&gt;
curl -v telnet://ip:port
&lt;/code&gt;&lt;/pre&gt;
&lt;code&gt;ip:&lt;/code&gt; the host that we want to check.&lt;/br&gt;
&lt;code&gt;port:&lt;/code&gt; the port that we want to validate.&lt;/br&gt;
&lt;/br&gt;
&lt;p&gt;&lt;h3&gt;Example&lt;/p&gt;&lt;/h3&gt;
Let&#39;s try to check if my RasberryPi is using the default ssh port.
&lt;pre&gt;&lt;code class=&quot;brush:bash&quot;&gt;
curl  -v telnet://192.168.1.138:22
&lt;/code&gt;&lt;/pre&gt;

The response is something like this:
&lt;code&gt;
&lt;pre&gt;
*   Trying 192.168.1.138:22...
* TCP_NODELAY set
* Connected to 192.168.1.138 (192.168.1.138) port 22 (#0)
SSH-2.0-OpenSSH_8.4p1 Debian-5+deb11u1
&lt;/pre&gt;
&lt;/code&gt;

&lt;a href=&quot;https://stackoverflow.com/questions/20434620/can-curl-make-a-connection-to-any-tcp-ports-not-just-http-https&quot; target=&quot;_blank&quot;&gt;source&lt;/a&gt;</content><link rel='replies' type='application/atom+xml' href='http://pintoland.blogspot.com/feeds/4397974396270063513/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/1657736901030895703/4397974396270063513' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1657736901030895703/posts/default/4397974396270063513'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1657736901030895703/posts/default/4397974396270063513'/><link rel='alternate' type='text/html' href='http://pintoland.blogspot.com/2022/08/check-ports-if-we-dont-have-access-to.html' title='Check ports if we don&#39;t have access to Telnet'/><author><name>Fabián Pinto</name><uri>http://www.blogger.com/profile/03020316804062827481</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjjBT1cIyxpb3rWvPknQdrqXFPxQKVpc6Wre53OWSYByRw5C8IWvRHX3_B0IkuXPkZ8XKqCf3SoCac-wcQkZrrftE1jQyXHTM-wPddFglilI2iJIbYidRqLpPTKbqyAHIJhe8Xw37NL-iIXYUUxKnQy-pNrjV6LdRfwKW-_xaIKF6o/s220/321233897_3296355443911743_3463809348725319721_n.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1657736901030895703.post-1541430611745768125</id><published>2019-02-08T01:11:00.001-03:00</published><updated>2022-08-24T23:08:52.299-04:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="DOS"/><category scheme="http://www.blogger.com/atom/ns#" term="Terminal"/><category scheme="http://www.blogger.com/atom/ns#" term="windows"/><title type='text'>Format an USB  with the command line in windows</title><content type='html'>&lt;br /&gt;
I needed to format a USB after putting an ISO in it, here&#39;s how it can be done.&lt;br /&gt;
&lt;br /&gt;
Now in D.O.S write:&lt;br /&gt;
&lt;br /&gt;
&lt;code&gt;diskpart.exe&lt;/code&gt;&lt;br /&gt;
&lt;br /&gt;
Now we are in the dispar utility so let&#39;s put the commands&lt;br /&gt;
&lt;br /&gt;
&lt;code&gt;list disk&lt;/code&gt;&lt;br /&gt;
&lt;br /&gt;
Disk ###  Status         Size     Free     Dyn  Gpt&lt;br /&gt;
--------  -------------  -------  -------  ---  ---&lt;br /&gt;
Disk 0    Online          238 GB  6144 KB&lt;br /&gt;
Disk 1    Online         1943 MB      0 B&lt;br /&gt;
&lt;br /&gt;
&lt;code&gt;select disk 1&lt;/code&gt;&lt;br /&gt;
&lt;pre&gt;Disk 1 is now the selected disk.&lt;/pre&gt;&lt;code&gt;clean&lt;/code&gt;&lt;br /&gt;
&lt;pre&gt;DiskPart succeeded in cleaning the disk.&lt;/pre&gt;&lt;code&gt;create partition primary&lt;/code&gt;&lt;br /&gt;
&lt;pre&gt;DiskPart succeeded in creating the specified partition.&lt;/pre&gt;&lt;code&gt;select partition 1&lt;/code&gt;&lt;br /&gt;
&lt;pre&gt;Partition 1 is now the selected partition.&lt;/pre&gt;&lt;code&gt;active&lt;/code&gt;&lt;br /&gt;
&lt;pre&gt;DiskPart marked the current partition as active.&lt;/pre&gt;&lt;code&gt;format fs=ntfs quick&lt;/code&gt;&lt;br /&gt;
&lt;pre&gt;100 percent completed
DiskPart successfully formatted the volume.&lt;/pre&gt;&lt;code&gt;exit&lt;/code&gt;&lt;br /&gt;
&lt;pre&gt;Leaving DiskPart...&lt;/pre&gt;</content><link rel='replies' type='application/atom+xml' href='http://pintoland.blogspot.com/feeds/1541430611745768125/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/1657736901030895703/1541430611745768125' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1657736901030895703/posts/default/1541430611745768125'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1657736901030895703/posts/default/1541430611745768125'/><link rel='alternate' type='text/html' href='http://pintoland.blogspot.com/2019/02/format-usb-with-comand-line-in-windows.html' title='Format an USB  with the command line in windows'/><author><name>Fabián Pinto</name><uri>http://www.blogger.com/profile/03020316804062827481</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjjBT1cIyxpb3rWvPknQdrqXFPxQKVpc6Wre53OWSYByRw5C8IWvRHX3_B0IkuXPkZ8XKqCf3SoCac-wcQkZrrftE1jQyXHTM-wPddFglilI2iJIbYidRqLpPTKbqyAHIJhe8Xw37NL-iIXYUUxKnQy-pNrjV6LdRfwKW-_xaIKF6o/s220/321233897_3296355443911743_3463809348725319721_n.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1657736901030895703.post-5870647578069170174</id><published>2017-03-05T21:50:00.002-03:00</published><updated>2021-12-08T02:28:07.398-03:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="Python"/><title type='text'>Add and subtract days to a Date in Python 2</title><content type='html'>A few days back in the place where i work in the moment one of the reports was failing or at least one of the day was  missing, the problem was the way of how it was getting the name of a file in it, the code was something like this in the script.&lt;br /&gt;
&lt;br /&gt;
&lt;pre&gt;&lt;code class=python&gt;import datetime
now = datetime.datetime.now()
# we need the file of yesterday
myfile = &#39;/home/dev/file_&#39; + str(now.day - 1) + &#39;_&#39; + str(now.month) + &#39;_&#39; + str(now.year) +&#39;.csv&#39;
&lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;
This look pretty and all but the problem was when the day is 1 the file of yesterday is not present because the day zero doesn&#39;t exist, so a better way of doing this is like:&lt;br /&gt;
&lt;br /&gt;
&lt;pre&gt;&lt;code class=python&gt;import datetime
yesterday = datetime.datetime.now() - datetime.timedelta(1)
# we need the file of yesterday
myfile = &#39;/home/dev/file_&#39; + str(yesterday.day) + &#39;_&#39; + str(yesterday.month) + &#39;_&#39; + str(yesterday.year) + &#39;.csv&#39;
&lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;
We can add days if we want like this&lt;br /&gt;
&lt;br /&gt;
&lt;a href=&quot;http://www.marinamele.com/2014/03/13-useful-tips-about-python-datetime.html&quot;&gt;source&lt;/a&gt;</content><link rel='replies' type='application/atom+xml' href='http://pintoland.blogspot.com/feeds/5870647578069170174/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/1657736901030895703/5870647578069170174' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1657736901030895703/posts/default/5870647578069170174'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1657736901030895703/posts/default/5870647578069170174'/><link rel='alternate' type='text/html' href='http://pintoland.blogspot.com/2017/03/add-and-subtract-days-to-date-in-python.html' title='Add and subtract days to a Date in Python 2'/><author><name>Fabián Pinto</name><uri>http://www.blogger.com/profile/03020316804062827481</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjjBT1cIyxpb3rWvPknQdrqXFPxQKVpc6Wre53OWSYByRw5C8IWvRHX3_B0IkuXPkZ8XKqCf3SoCac-wcQkZrrftE1jQyXHTM-wPddFglilI2iJIbYidRqLpPTKbqyAHIJhe8Xw37NL-iIXYUUxKnQy-pNrjV6LdRfwKW-_xaIKF6o/s220/321233897_3296355443911743_3463809348725319721_n.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1657736901030895703.post-4771867272797858457</id><published>2016-12-03T21:55:00.002-03:00</published><updated>2022-08-24T23:14:25.227-04:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="bash"/><title type='text'>Download youtube videos as a mp3 using youtube-dl </title><content type='html'>so you only need &lt;code&gt;youtube-dl&lt;/code&gt; and &lt;code&gt;ffmpeg&lt;/code&gt; and if you want your  mp3 file with metadata like the artist and title we can use the  next command line:&lt;br /&gt;
&lt;br /&gt;
&lt;pre&gt;&lt;code class=&quot;brush:bash&quot;&gt;youtube-dl --prefer-ffmpeg --extract-audio --audio-format mp3 --audio-quality 1 -o &#39;%(title)s.%(ext)s&#39; --metadata-from-title &#39;%(artist)s - %(track)s&#39; --add-metadata
&lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;
&lt;h3&gt;Let&#39;s explain  some of the argument&lt;/h3&gt;&lt;br /&gt;
&lt;code&gt;--extract-audio&lt;/code&gt;: Convert video files to audio-only files&lt;br /&gt;
&lt;code&gt;--audio-format&lt;/code&gt;: Format of the audio file&lt;br /&gt;
&lt;code&gt;--audio-quality&lt;/code&gt;: Quality of the audio can be between 0 (better) and 9 (worse)&lt;br /&gt;
&lt;code&gt;-o or --output&lt;/code&gt;: How we want to name the file &lt;br /&gt;
&lt;code&gt;--metadata-from-title&lt;/code&gt;: Parse additional metadata from the video title the format like &lt;code&gt;--output&lt;/code&gt;&lt;br /&gt;
&lt;code&gt;--add-metadata&lt;/code&gt;: Actually write the metadata in the file&lt;br /&gt;
&lt;br /&gt;
&lt;a href=&quot;https://github.com/rg3/youtube-dl#output-template-examples&quot;&gt;Documentation&lt;/a&gt; </content><link rel='replies' type='application/atom+xml' href='http://pintoland.blogspot.com/feeds/4771867272797858457/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/1657736901030895703/4771867272797858457' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1657736901030895703/posts/default/4771867272797858457'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1657736901030895703/posts/default/4771867272797858457'/><link rel='alternate' type='text/html' href='http://pintoland.blogspot.com/2016/12/download-youtube-videos-as-mp3-using.html' title='Download youtube videos as a mp3 using youtube-dl '/><author><name>Fabián Pinto</name><uri>http://www.blogger.com/profile/03020316804062827481</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjjBT1cIyxpb3rWvPknQdrqXFPxQKVpc6Wre53OWSYByRw5C8IWvRHX3_B0IkuXPkZ8XKqCf3SoCac-wcQkZrrftE1jQyXHTM-wPddFglilI2iJIbYidRqLpPTKbqyAHIJhe8Xw37NL-iIXYUUxKnQy-pNrjV6LdRfwKW-_xaIKF6o/s220/321233897_3296355443911743_3463809348725319721_n.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1657736901030895703.post-2309947955953238574</id><published>2015-12-21T01:57:00.001-03:00</published><updated>2017-04-23T23:50:14.346-03:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="cli"/><category scheme="http://www.blogger.com/atom/ns#" term="linux"/><category scheme="http://www.blogger.com/atom/ns#" term="ubuntu"/><title type='text'>Traps in a file, in smnpd not using the default port</title><content type='html'>&lt;h3&gt;INTRO&lt;/h3&gt;well for this I am going to write this in English because it was difficult to get this to work properly&lt;br /&gt;
&lt;br /&gt;
the business rule is as follows:&lt;br /&gt;
&lt;br /&gt;
let&#39;s get some traps from a device to our machine to port 8080 and we have to  stored in a file somewhere.&lt;br /&gt;
&lt;h3&gt;&lt;b&gt;Install the snmpd im using ubuntu so:&lt;/b&gt;&lt;/h3&gt;&lt;br /&gt;
&lt;pre class=&quot;brush:bash&quot;&gt;apt-get install snmpd
&lt;/pre&gt;&lt;br /&gt;
&lt;h3&gt;&lt;b&gt;Save the traps in a file:&lt;/b&gt;&lt;/h3&gt;&lt;br /&gt;
we need to modify the file &lt;code&gt;/etc/default/snmpd&lt;/code&gt; and change the variables to this:&lt;br /&gt;
&lt;br /&gt;
&lt;pre class=&quot;brush:bash&quot;&gt;TRAPDRUN=yes

TRAPDOPTS=&#39;-A -Lf /var/log/snmptrapd.log -p /var/run/snmptrapd.pid’
&lt;/pre&gt;the traps are stored in  &lt;code&gt;/var/log/snmptrapd.log&lt;/code&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;h3&gt;&lt;b&gt;Configure the &quot;community string&quot; and the port for listen:&lt;/b&gt;&lt;/h3&gt;&lt;br /&gt;
we need to open  the file &lt;code&gt;/etc/snmp/snmptrapd.conf&lt;/code&gt; and write this.&lt;br /&gt;
&lt;br /&gt;
&lt;pre class=&quot;brush:bash&quot;&gt;snmpTrapdAddr udp:8080
authCommunity log public
&lt;/pre&gt;&lt;br /&gt;
we are listen in the 8080 via udp package.&lt;br /&gt;
&quot;public&quot; is the community string ,change this to match with your case scenario.&lt;br /&gt;
&lt;br /&gt;
&lt;h3&gt;&lt;b&gt;Restart the service&lt;/b&gt;&lt;/h3&gt;&lt;pre class=&quot;brush:bash&quot;&gt;service snmpd restart
&lt;/pre&gt;&lt;br /&gt;
&lt;h3&gt;&lt;b&gt;Simulate traps&lt;/b&gt;&lt;/h3&gt;we can do this with this command if we are in the machine(localhost).&lt;br /&gt;
&lt;br /&gt;
&lt;pre class=&quot;brush:bash&quot;&gt;snmptrap -v 1 -c public 127.0.0.1:8080 .1.3.6.1 localhost 6 17 &#39;&#39; .1.3.6.1 s &quot;Just a test&quot;
&lt;/pre&gt;&lt;br /&gt;
you can change the &lt;code&gt;127.0.0.1&lt;/code&gt; for the address of the machine if you are trying to test from another machine&lt;br /&gt;
&lt;br /&gt;
&lt;h3&gt;&lt;b&gt;Troubleshooting&lt;/b&gt;&lt;/h3&gt;&lt;br /&gt;
check if indeed it is listening for the corresponding port:&lt;br /&gt;
&lt;br /&gt;
&lt;pre class=&quot;brush:bash&quot;&gt;netstat -lnp | grep snmp
&lt;/pre&gt;&lt;br /&gt;
and we get something like this:&lt;br /&gt;
&lt;code&gt;&lt;br /&gt;
udp        0      0 0.0.0.0:42385           0.0.0.0:*                           957/snmpd&lt;br /&gt;
udp        0      0 127.0.0.1:161           0.0.0.0:*                           957/snmpd&lt;br /&gt;
udp        0      0 0.0.0.0:164             0.0.0.0:*                           962/snmptrapd&lt;br /&gt;
unix  2      [ ACC ]     STREAM     LISTENING     9632     957/snmpd           /var/agentx/master&lt;br /&gt;
&lt;/code&gt;&lt;br /&gt;
&lt;br /&gt;
other way is using &lt;code&gt;nmap&lt;/code&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;pre class=&quot;brush:bash&quot;&gt;nmap -sU localhost
&lt;/pre&gt;&lt;br /&gt;
the output is something like this:&lt;br /&gt;
&lt;br /&gt;
&lt;code&gt;&lt;br /&gt;
Starting Nmap 5.21 ( http://nmap.org ) at 2015-12-21 01:51 CLT&lt;br /&gt;
Nmap scan report for localhost (127.0.0.1)&lt;br /&gt;
Host is up (0.0000080s latency).&lt;br /&gt;
Not shown: 997 closed ports&lt;br /&gt;
PORT    STATE         SERVICE&lt;br /&gt;
68/udp  open|filtered dhcpc&lt;br /&gt;
161/udp open          snmp&lt;br /&gt;
162/udp open|filtered snmptrap&lt;br /&gt;
&lt;br /&gt;
Nmap done: 1 IP address (1 host up) scanned in 1.24 seconds&lt;br /&gt;
&lt;/code&gt;&lt;br /&gt;
&lt;br /&gt;
anyway you can hear the port to see if it reaches something and verify that the community string is the same, we lost so much time because of a bad  string they gave us&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;a href=&quot;https://mathias-kettner.de/checkmk_mkeventd_traps.html&quot; target=_blank&gt;fuente1&lt;/a&gt;&lt;br /&gt;
&lt;a href=&quot;https://answers.splunk.com/answers/229041/how-to-send-snmp-traps-from-my-linux-machine-to-a.html&quot; target=_blank&gt;fuente2&lt;/a&gt;</content><link rel='replies' type='application/atom+xml' href='http://pintoland.blogspot.com/feeds/2309947955953238574/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/1657736901030895703/2309947955953238574' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1657736901030895703/posts/default/2309947955953238574'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1657736901030895703/posts/default/2309947955953238574'/><link rel='alternate' type='text/html' href='http://pintoland.blogspot.com/2015/12/traps-in-file-in-smnpd-not-using.html' title='Traps in a file, in smnpd not using the default port'/><author><name>Fabián Pinto</name><uri>http://www.blogger.com/profile/03020316804062827481</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjjBT1cIyxpb3rWvPknQdrqXFPxQKVpc6Wre53OWSYByRw5C8IWvRHX3_B0IkuXPkZ8XKqCf3SoCac-wcQkZrrftE1jQyXHTM-wPddFglilI2iJIbYidRqLpPTKbqyAHIJhe8Xw37NL-iIXYUUxKnQy-pNrjV6LdRfwKW-_xaIKF6o/s220/321233897_3296355443911743_3463809348725319721_n.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1657736901030895703.post-1625824251910363531</id><published>2015-09-22T00:30:00.002-03:00</published><updated>2022-08-24T23:31:00.249-04:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="bash"/><category scheme="http://www.blogger.com/atom/ns#" term="cli"/><category scheme="http://www.blogger.com/atom/ns#" term="code"/><title type='text'>Average in Bash</title><content type='html'>&lt;h2&gt;Problem&lt;/h2&gt;
Given &lt;code&gt;N&lt;/code&gt; integers, Show the average of &lt;code&gt;N&lt;/code&gt; integers with 3 decimal places.&lt;br /&gt;&lt;br /&gt;
&lt;b&gt;Input Format&lt;/b&gt;&lt;br /&gt;
La primera linea contiene 
The first line contain &lt;code&gt;N&lt;/code&gt; integers.&lt;code&gt;N&lt;/code&gt; lines with only one number.&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Output Fromat&lt;/b&gt;
&lt;br /&gt;
The integer with 3 decimal places.
&lt;br /&gt;
&lt;br /&gt;
&lt;h4&gt;Example&lt;/h4&gt;&lt;br /&gt;
&lt;b&gt;Input&lt;/b&gt;&lt;br /&gt;
&lt;code&gt;&lt;br /&gt;
4&lt;br /&gt;
1&lt;br /&gt;
2&lt;br /&gt;
9&lt;br /&gt;
8&lt;br /&gt;
&lt;/code&gt;&lt;br /&gt;
&lt;b&gt;Output&lt;/b&gt;&lt;br /&gt;
&lt;code&gt;&lt;br /&gt;
5.000&lt;br /&gt;
&lt;/code&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;h3&gt;Code&lt;/h3&gt;
&lt;pre&gt;&lt;code class=&quot;brush:bash&quot;&gt;read a
b=0
for (( c=1; c&lt;=$a; c++ ))
do
read d
b=$(($b+$d))
done
echo $(printf %.3f $(echo &quot;scale=4;($b/$a)&quot; | bc))
&lt;/code&gt;&lt;/pre&gt;
</content><link rel='replies' type='application/atom+xml' href='http://pintoland.blogspot.com/feeds/1625824251910363531/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/1657736901030895703/1625824251910363531' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1657736901030895703/posts/default/1625824251910363531'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1657736901030895703/posts/default/1625824251910363531'/><link rel='alternate' type='text/html' href='http://pintoland.blogspot.com/2015/09/calculando-el-promedio-en-bash.html' title='Average in Bash'/><author><name>Fabián Pinto</name><uri>http://www.blogger.com/profile/03020316804062827481</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjjBT1cIyxpb3rWvPknQdrqXFPxQKVpc6Wre53OWSYByRw5C8IWvRHX3_B0IkuXPkZ8XKqCf3SoCac-wcQkZrrftE1jQyXHTM-wPddFglilI2iJIbYidRqLpPTKbqyAHIJhe8Xw37NL-iIXYUUxKnQy-pNrjV6LdRfwKW-_xaIKF6o/s220/321233897_3296355443911743_3463809348725319721_n.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1657736901030895703.post-3805888275534650738</id><published>2015-09-21T08:11:00.004-03:00</published><updated>2022-08-24T23:41:01.945-04:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="bash"/><category scheme="http://www.blogger.com/atom/ns#" term="cli"/><category scheme="http://www.blogger.com/atom/ns#" term="code"/><title type='text'>Odd numbers in bash using a loop</title><content type='html'>Lately I&#39;ve been kind of bored so instead of playing I&#39;ve been entertaining myself by solving programming problems, one very easy this one.&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Show the odd numbers from  1 until 99 using bash&lt;/b&gt;&lt;br /&gt;
&lt;h3&gt;code&lt;/h3&gt;
&lt;pre&gt;&lt;code class=&quot;brush:bash&quot;&gt;for i in {1..99}
do
if(( $i % 2 != 0 ))
then
echo &quot;$i&quot;
fi
done
&lt;/code&gt;&lt;/pre&gt;</content><link rel='replies' type='application/atom+xml' href='http://pintoland.blogspot.com/feeds/3805888275534650738/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/1657736901030895703/3805888275534650738' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1657736901030895703/posts/default/3805888275534650738'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1657736901030895703/posts/default/3805888275534650738'/><link rel='alternate' type='text/html' href='http://pintoland.blogspot.com/2015/09/calculando-numeros-impares-en-bash.html' title='Odd numbers in bash using a loop'/><author><name>Fabián Pinto</name><uri>http://www.blogger.com/profile/03020316804062827481</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjjBT1cIyxpb3rWvPknQdrqXFPxQKVpc6Wre53OWSYByRw5C8IWvRHX3_B0IkuXPkZ8XKqCf3SoCac-wcQkZrrftE1jQyXHTM-wPddFglilI2iJIbYidRqLpPTKbqyAHIJhe8Xw37NL-iIXYUUxKnQy-pNrjV6LdRfwKW-_xaIKF6o/s220/321233897_3296355443911743_3463809348725319721_n.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1657736901030895703.post-8071230498477459195</id><published>2015-09-19T15:39:00.002-03:00</published><updated>2022-08-25T02:10:56.574-04:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="cli"/><category scheme="http://www.blogger.com/atom/ns#" term="tmux"/><title type='text'>Using  Tmux</title><content type='html'>&lt;code&gt;tmux&lt;/code&gt; lo conoci en una charla que vi en youtube y expandí mis conocimientos usando un libro he aquí un resumen para que les sea útil.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;h2&gt;Comandos&lt;/h2&gt;&lt;br /&gt;
&lt;b&gt;Nueva sesión&lt;/b&gt;&lt;br /&gt;
&lt;code&gt;tmux new -s miSesion&lt;/code&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Ver las distintas sesiones&lt;/b&gt;&lt;br /&gt;
&lt;code&gt;tmux ls&lt;/code&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Crear una nueva sesión pero que quede funcionando por detrás&lt;/b&gt;&lt;br /&gt;
&lt;code&gt;tmux new -s miSesion -d&lt;/code&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Volver a una sesión&lt;/b&gt;&lt;br /&gt;
&lt;code&gt;tmux attach -t miSesion&lt;/code&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Matar una sesión&lt;/b&gt;&lt;br /&gt;
&lt;code&gt;tmux kill-session -t miSesion&lt;/code&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Crea una nueva sesión con un nombre en la ventana&lt;/b&gt;&lt;br /&gt;
&lt;code&gt;tmux new -s miSesion -n miVentana&lt;/code&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Salir o salir ventana&lt;/b&gt;&lt;br /&gt;
&lt;code&gt;exit&lt;/code&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;h2&gt;Hotkeys&lt;/h2&gt;&lt;br /&gt;
El prefijo por defecto es &lt;code&gt;Ctrl + b&lt;/code&gt; sin embargo se puede cambiar.&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Crea una nueva ventana en tmux&lt;/b&gt;&lt;br /&gt;
&lt;code&gt;prefix + c&lt;/code&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Renombrar la ventana&lt;/b&gt;&lt;br /&gt;
&lt;code&gt;prefix + ,&lt;/code&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Ir a la ventana previa&lt;/b&gt;&lt;br /&gt;
&lt;code&gt;prefix + p&lt;/code&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Ir a la ventana siguiente&lt;/b&gt;&lt;br /&gt;
&lt;code&gt;prefix + n&lt;/code&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Ir a la ventana nº 1&lt;/b&gt;&lt;br /&gt;
&lt;code&gt;prefix + 1&lt;/code&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Salir de la ventana&lt;/b&gt;&lt;br /&gt;
&lt;code&gt;prefix + &amp;amp;&lt;/code&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Dettach&lt;/b&gt;&lt;br /&gt;
&lt;code&gt;prefix + d&lt;/code&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Divide la pantalla Vertical&lt;/b&gt;&lt;br /&gt;
&lt;code&gt;prefix + %&lt;/code&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Divide la pantalla Horizontal&lt;/b&gt;&lt;br /&gt;
&lt;code&gt;prefix + &quot;&lt;/code&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Salta al panel según la dirección&lt;/b&gt;&lt;br /&gt;
&lt;code&gt;prefix +{&amp;larr; &amp;uarr; &amp;rarr; &amp;darr;}&lt;/code&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Cambiamos de posición los paneles dependiendo la configuración por defecto&lt;/b&gt;&lt;br /&gt;
&lt;code&gt;prefix + space&lt;/code&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Cierra el panel que estamos ocupando&lt;/b&gt;&lt;br /&gt;
&lt;code&gt;prefix + x&lt;/code&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Pasar al modo comando&lt;/b&gt;&lt;br /&gt;
&lt;code&gt;prefix + :&lt;/code&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Mostrar toda las combinaciones de botones&lt;/b&gt;&lt;br /&gt;
&lt;code&gt;prefix + ?&lt;/code&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;h2&gt;Inicio automatizado&lt;/h2&gt;&lt;br /&gt;
Para usar  una configuración para llamarlo de alguna forma se debe usar el siguiente comando:&lt;br /&gt;
&lt;code&gt;tmux -f miConfig.conf attach&lt;/code&gt;&lt;br /&gt;
&lt;br /&gt;
la siguiente configuración lo que hace es crear 4 ventanas con sus respectivos nombres  ya que asi tenia disponible las vistas,modelos y controladores de una pagina web la cual estaba construyendo.&lt;br /&gt;
&lt;br /&gt;
&lt;code&gt;&lt;br /&gt;
source-file ~/.tmux.conf&lt;br /&gt;
new-session -s admin -n model&lt;br /&gt;
new-window -n controller -t admin&lt;br /&gt;
new-window -n view -t admin&lt;br /&gt;
new-window -n config -t admin&lt;br /&gt;
send-keys -t model &#39;cd /home/ubuntu/ad/app/Model&#39; C-m&lt;br /&gt;
send-keys -t controller &#39;cd /home/ubuntu/ad/app/Controller&#39; C-m&lt;br /&gt;
send-keys -t view &#39;cd /home/ubuntu/ad/app/View&#39; C-m&lt;br /&gt;
send-keys -t config &#39;cd /home/ubuntu/ad/app/Config&#39; C-m&lt;br /&gt;
&lt;/code&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;h2&gt;Mi configuración&lt;/h2&gt;&lt;br /&gt;
La configuración de tmux se puede configurar colocando algunas cosas en el archivo .tmux.conf por ejemplo yo cambie el prefijo a &lt;code&gt;Ctrl + a&lt;/code&gt;  como se usa en &quot;screen&quot;, para que tome los cambios  se necesita hacer en el modo comando &lt;code&gt;source-file ~/.tmux.conf&lt;/code&gt; o en otro archivo de configuración como en el ejemplo anterior.&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;.tmux.conf&lt;/b&gt;&lt;br /&gt;
&lt;code&gt;&lt;br /&gt;
#Prefix es Ctrl-a&lt;br /&gt;
set -g prefix C-a&lt;br /&gt;
bind C-a send-prefix&lt;br /&gt;
#Sacamos Ctrl-b&lt;br /&gt;
unbind C-b&lt;br /&gt;
#Cambiamos el Delay&lt;br /&gt;
set -sg escape-time 1&lt;br /&gt;
#Cambiamos el inicio de las ventanas a 1&lt;br /&gt;
set -g base-index 1&lt;br /&gt;
#Cambiamos el inicio para los paneles&lt;br /&gt;
setw -g pane-base-index 1&lt;br /&gt;
#Recargar nuestra configuracion a tmux&lt;br /&gt;
bind r source-file ~/.tmux.conf \; display &quot;Reloaded!&quot;&lt;br /&gt;
#Paneles&lt;br /&gt;
bind | split-window -h&lt;br /&gt;
bind - split-window -v&lt;br /&gt;
#Mouse works as expected&lt;br /&gt;
setw -g mode-mouse on&lt;br /&gt;
set -g mouse-select-pane on&lt;br /&gt;
set -g mouse-resize-pane on&lt;br /&gt;
set -g mouse-select-window on&lt;br /&gt;
&lt;br /&gt;
setw -g monitor-activity on&lt;br /&gt;
set -g visual-activity on&lt;br /&gt;
&lt;br /&gt;
set -g mode-keys vi&lt;br /&gt;
set -g history-limit 10000&lt;br /&gt;
&lt;br /&gt;
# y and p as in vim&lt;br /&gt;
bind Escape copy-mode&lt;br /&gt;
unbind p&lt;br /&gt;
bind p paste-buffer&lt;br /&gt;
bind -t vi-copy &#39;v&#39; begin-selection&lt;br /&gt;
bind -t vi-copy &#39;y&#39; copy-selection&lt;br /&gt;
bind -t vi-copy &#39;Space&#39; halfpage-down&lt;br /&gt;
bind -t vi-copy &#39;Bspace&#39; halfpage-up&lt;br /&gt;
&lt;br /&gt;
# extra commands for interacting with the ICCCM clipboard&lt;br /&gt;
bind C-c run &quot;tmux save-buffer - | xclip -i -sel clipboard&quot;&lt;br /&gt;
bind C-v run &quot;tmux set-buffer \&quot;$(xclip -o -sel clipboard)\&quot;; tmux paste-buffer&quot;&lt;br /&gt;
#set -g default-command &quot;reattach-to-user-namespace -l /bin/bash&quot;&lt;br /&gt;
#bind C-c run &quot;tmux save-buffer - | reattach-to-user-namespace pbcopy&quot;&lt;br /&gt;
#bind C-v run &quot;tmux set-buffer $(reattach-to-user-namespace pbpaste);tmux paste-buffer&quot;&lt;br /&gt;
&lt;br /&gt;
# easy-to-remember split pane commands&lt;br /&gt;
bind | split-window -h&lt;br /&gt;
bind - split-window -v&lt;br /&gt;
unbind &#39;&quot;&#39;&lt;br /&gt;
unbind %&lt;br /&gt;
&lt;br /&gt;
# moving between panes with vim movement keys&lt;br /&gt;
bind h select-pane -L&lt;br /&gt;
bind j select-pane -D&lt;br /&gt;
bind k select-pane -U&lt;br /&gt;
bind l select-pane -R&lt;br /&gt;
&lt;br /&gt;
# moving between windows with vim movement keys&lt;br /&gt;
bind -r C-h select-window -t :-&lt;br /&gt;
bind -r C-l select-window -t :+&lt;br /&gt;
# resize panes with vim movement keys&lt;br /&gt;
bind -r H resize-pane -L 5&lt;br /&gt;
bind -r J resize-pane -D 5&lt;br /&gt;
bind -r K resize-pane -U 5&lt;br /&gt;
bind -r L resize-pane -R 5&lt;br /&gt;
# Highlight active window&lt;br /&gt;
setw -g window-status-fg white&lt;br /&gt;
setw -g window-status-bg black&lt;br /&gt;
setw -g window-status-attr bright&lt;br /&gt;
# Color para los paneles&lt;br /&gt;
set -g pane-border-fg green&lt;br /&gt;
set -g pane-border-bg black&lt;br /&gt;
set -g pane-active-border-fg white&lt;br /&gt;
set -g pane-active-border-bg yellow&lt;br /&gt;
# Modo vi para moverse por el buffer&lt;br /&gt;
#setw -g mode-keys v&lt;br /&gt;
# Modificando el status-bar&lt;br /&gt;
set -g status-left-length 40&lt;br /&gt;
set -g status-left &quot;#[fg=red]Session: #S #[fg=green]#I #[fg=black]#P&quot;&lt;br /&gt;
set -g status-right &quot;#[fg=black]%d %b %R&quot;&lt;br /&gt;
# Color de la status bar completa&lt;br /&gt;
set -g status-bg white&lt;br /&gt;
set -g status-utf8 on&lt;br /&gt;
## Ventanas en el centro&lt;br /&gt;
set -g status-justify centre&lt;br /&gt;
# Para tener los 256 colores&lt;br /&gt;
set -g default-terminal &quot;screen-256color&quot;&lt;br /&gt;
&lt;/code&gt;</content><link rel='replies' type='application/atom+xml' href='http://pintoland.blogspot.com/feeds/8071230498477459195/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/1657736901030895703/8071230498477459195' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1657736901030895703/posts/default/8071230498477459195'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1657736901030895703/posts/default/8071230498477459195'/><link rel='alternate' type='text/html' href='http://pintoland.blogspot.com/2015/09/tmux.html' title='Using  Tmux'/><author><name>Fabián Pinto</name><uri>http://www.blogger.com/profile/03020316804062827481</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjjBT1cIyxpb3rWvPknQdrqXFPxQKVpc6Wre53OWSYByRw5C8IWvRHX3_B0IkuXPkZ8XKqCf3SoCac-wcQkZrrftE1jQyXHTM-wPddFglilI2iJIbYidRqLpPTKbqyAHIJhe8Xw37NL-iIXYUUxKnQy-pNrjV6LdRfwKW-_xaIKF6o/s220/321233897_3296355443911743_3463809348725319721_n.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1657736901030895703.post-8649100019954450162</id><published>2015-09-06T23:45:00.004-03:00</published><updated>2022-08-25T02:20:18.257-04:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="code"/><category scheme="http://www.blogger.com/atom/ns#" term="ruby"/><title type='text'>How many primes less than or equal to n exists?</title><content type='html'>In &lt;a href=&quot;http://hackealo.co&quot; target=_blank&gt;hackealo.co&lt;/a&gt; there was another problem and Ruby&#39;s solution was easier than I expected&lt;br /&gt;
&lt;code&gt;How many primes less than or equal to 7293 exits?&lt;/code&gt;&lt;br /&gt;
&lt;pre&gt;&lt;code class=&quot;ruby&quot;&gt;
#!/usr/bin/env ruby
require &#39;mathn&#39;
s=0
Prime.each(7293) do |prime|
     s+=1
end
puts &#39;resultado:&#39;+s.to_s&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;source&lt;/p&gt;&lt;br /&gt;
&lt;a href=&quot;https://repl.it/languages/ruby&quot; target=_blank&gt;Ruby online&lt;/a&gt;&lt;br /&gt;
&lt;a href=&quot;http://ruby-doc.org/stdlib-1.9.3/libdoc/prime/rdoc/Prime.html&quot; target=_blank&gt;Prime numbers in Ruby&lt;/a&gt;</content><link rel='replies' type='application/atom+xml' href='http://pintoland.blogspot.com/feeds/8649100019954450162/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/1657736901030895703/8649100019954450162' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1657736901030895703/posts/default/8649100019954450162'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1657736901030895703/posts/default/8649100019954450162'/><link rel='alternate' type='text/html' href='http://pintoland.blogspot.com/2015/09/cuantos-primos-menores-o-iguales-n.html' title='How many primes less than or equal to n exists?'/><author><name>Fabián Pinto</name><uri>http://www.blogger.com/profile/03020316804062827481</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjjBT1cIyxpb3rWvPknQdrqXFPxQKVpc6Wre53OWSYByRw5C8IWvRHX3_B0IkuXPkZ8XKqCf3SoCac-wcQkZrrftE1jQyXHTM-wPddFglilI2iJIbYidRqLpPTKbqyAHIJhe8Xw37NL-iIXYUUxKnQy-pNrjV6LdRfwKW-_xaIKF6o/s220/321233897_3296355443911743_3463809348725319721_n.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1657736901030895703.post-5545129894278758250</id><published>2015-09-06T23:36:00.004-03:00</published><updated>2023-01-06T23:14:01.311-03:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="programing"/><category scheme="http://www.blogger.com/atom/ns#" term="ruby"/><title type='text'>The sum of smaller prime numbers equal to &quot;n&quot;</title><content type='html'>In &lt;a href=&quot;http://hackealo.co&quot; target=_blank&gt;hackealo.co&lt;/a&gt; aggain there was another problem and the Ruby solution was easier than I expected.&lt;br /&gt;
&lt;code&gt;What is the sum of all primes less than or equal to 5936?&lt;/code&gt;&lt;br /&gt;
&lt;pre class=&quot;brush:ruby&quot;&gt;#!/usr/bin/env ruby
require &#39;mathn&#39;
s=0
Prime.each(5936) do |prime|
     s+=prime
end
puts &#39;result:&#39;+s.to_s
&lt;/pre&gt;fuente&lt;br /&gt;
&lt;a href=&quot;http://ruby-doc.org/stdlib-1.9.3/libdoc/prime/rdoc/Prime.html&quot; target=_blank&gt;Prime Numbers in Ruby&lt;/a&gt;</content><link rel='replies' type='application/atom+xml' href='http://pintoland.blogspot.com/feeds/5545129894278758250/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/1657736901030895703/5545129894278758250' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1657736901030895703/posts/default/5545129894278758250'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1657736901030895703/posts/default/5545129894278758250'/><link rel='alternate' type='text/html' href='http://pintoland.blogspot.com/2015/09/la-suma-de-numeros-primos-menores.html' title='The sum of smaller prime numbers equal to &quot;n&quot;'/><author><name>Fabián Pinto</name><uri>http://www.blogger.com/profile/03020316804062827481</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjjBT1cIyxpb3rWvPknQdrqXFPxQKVpc6Wre53OWSYByRw5C8IWvRHX3_B0IkuXPkZ8XKqCf3SoCac-wcQkZrrftE1jQyXHTM-wPddFglilI2iJIbYidRqLpPTKbqyAHIJhe8Xw37NL-iIXYUUxKnQy-pNrjV6LdRfwKW-_xaIKF6o/s220/321233897_3296355443911743_3463809348725319721_n.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1657736901030895703.post-9195638253156801212</id><published>2015-09-06T22:51:00.000-03:00</published><updated>2015-09-06T22:55:06.558-03:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="algoritmo"/><category scheme="http://www.blogger.com/atom/ns#" term="problema"/><category scheme="http://www.blogger.com/atom/ns#" term="ruby"/><title type='text'>el problema de ordenar las letras  segun la cantidad de apariciones</title><content type='html'>en &lt;a href=&quot;http://hackealo.co/&quot; target=_blank &gt;hackealo.co/&lt;/a&gt; presentan el siguiente problema y de aburrido me  dedique a resolverlo con Ruby de la siguiente manera:&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;El problema&lt;br /&gt;
&lt;/b&gt;&lt;br /&gt;
Dado el siguiente String:&lt;br /&gt;
&lt;br /&gt;
&lt;code&gt;uhERnSOTIiZJTMxuvVLATRfboavhtRwlyUKacuYlOopNWnoMWrUHCEtpcwzEYTWVptoxOlyHEeUMeMcbfEyjAVylxRpxVCRUCXAJFjUGSEUgQxJwrgGEPvIXInuFOAkcXjLdmPmiIzNWUXhYePvckLQotpAUTosytjPjxsRDPDebUXCVOTBrpjrchwLeVgnsaMDVztV&lt;/code&gt;&lt;br /&gt;
&lt;br /&gt;
Ordenar las siguientes letras del alfabeto según cantidad de apariciones, de mayor a menor (en caso de empate, considerar órden alfabético).La respuesta debe estar en minúscula y sin letras repetidas.&lt;br /&gt;
&lt;br /&gt;
&lt;pre class=&quot;brush: ruby&quot;&gt;#!/usr/bin/env ruby
letras=&quot;uhERnSOTIiZJTMxuvVLATRfboavhtRwlyUKacuYlOopNWnoMWrUHCEtpcwzEYTWVptoxOlyHEeUMeMcbfEyjAVylxRpxVCRUCXAJFjUGSEUgQxJwrgGEPvIXInuFOAkcXjLdmPmiIzNWUXhYePvckLQotpAUTosytjPjxsRDPDebUXCVOTBrpjrchwLeVgnsaMDVztV&quot;
frase=letras.chars.sort { |a, b| a.casecmp(b) }.join.downcase
#puts frase.inspect
contador=frase.scan(/\w/).inject(Hash.new(0)){|h, c| h[c] += 1; h}
#puts contador.inspect
orden=contador.sort { |x, y| y[1] &lt;=&gt; x[1] }
#puts orden.inspect
semiresp=&quot;&quot;
temp=0
orden.each do |c|
if temp==c[1]
semiresp+=c[0]
else
semiresp+=&#39;,&#39;+c[0]
end
temp=c[1]
end
separado=semiresp.split(&#39;,&#39;)
resultado=&quot;&quot;
#puts separado.inspect
separado.each{|x| resultado+=x.chars.sort.join}
puts resultado.inspect
&lt;/pre&gt;fuente:&lt;br /&gt;
&lt;br /&gt;
&lt;a href=&quot;http://stackoverflow.com/questions/16124735/letter-count-in-a-sentence-using-ruby&quot; target=_blank&gt;Contar letras con ruby&lt;/a&gt;&lt;br /&gt;
&lt;a href=&quot;http://stackoverflow.com/questions/9464065/how-to-sort-a-strings-characters-alphabetically&quot; target=_blank&gt;ordenar las letras alfabeticamente en una frase&lt;/a&gt;&lt;br /&gt;
&lt;a href=&quot;https://repl.it/languages/ruby&quot;target=_blank&gt;interprete de ruby en linea&lt;/a&gt;&lt;br /&gt;
</content><link rel='replies' type='application/atom+xml' href='http://pintoland.blogspot.com/feeds/9195638253156801212/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/1657736901030895703/9195638253156801212' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1657736901030895703/posts/default/9195638253156801212'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1657736901030895703/posts/default/9195638253156801212'/><link rel='alternate' type='text/html' href='http://pintoland.blogspot.com/2015/09/el-problema-de-ordenar-las-letras-segun.html' title='el problema de ordenar las letras  segun la cantidad de apariciones'/><author><name>Fabián Pinto</name><uri>http://www.blogger.com/profile/03020316804062827481</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjjBT1cIyxpb3rWvPknQdrqXFPxQKVpc6Wre53OWSYByRw5C8IWvRHX3_B0IkuXPkZ8XKqCf3SoCac-wcQkZrrftE1jQyXHTM-wPddFglilI2iJIbYidRqLpPTKbqyAHIJhe8Xw37NL-iIXYUUxKnQy-pNrjV6LdRfwKW-_xaIKF6o/s220/321233897_3296355443911743_3463809348725319721_n.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1657736901030895703.post-8216036206781732353</id><published>2015-09-06T17:57:00.000-03:00</published><updated>2015-09-06T17:57:18.035-03:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="charlas"/><category scheme="http://www.blogger.com/atom/ns#" term="negocios"/><title type='text'>Comunicación Efectiva Con clientes, inversionistas y las personas que nos rodean de Daniela Serrano</title><content type='html'>Fui a la &lt;a href=&quot;http://www.devconchile.org/schedule/#session-223&quot; target=&quot;_blank&quot;&gt;DevCon&lt;/a&gt; y se dicto la siguiente charla por Daniela Serrano, aquí esta un resumen algunas cosas de las que dijo que están bastante interesantes.&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Comunicación con el equipo de trabajo&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
· Las conversaciones deberían ser breves:evitar las reuniones de 1 hr.&lt;br /&gt;
· Saber en que esta cada uno del equipo de trabajo: en que es lo que están trabajando&lt;br /&gt;
· Escuchar al equipo con atención&lt;br /&gt;
· Empezar el día con un repaso de 5 minutos: empezar con  un resumen en lo que se quedaron el día anterior&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;De que se quejan los Clientes&lt;/b&gt;&lt;br /&gt;
&lt;ul&gt; &lt;li&gt;Incumplimientos de promesas&lt;/li&gt;
 &lt;li&gt;La letra chica de los contratos&lt;/li&gt;
 &lt;li&gt;No dar solución a un problema&lt;/li&gt;
 &lt;li&gt;Mal servicio al clientes&lt;/li&gt;
 &lt;li&gt;Transferir de un agente de servicio al cliente a otro&lt;/li&gt;
 &lt;li&gt;Pocos medios de comunicación&lt;/li&gt;
 &lt;li&gt;Trato descortés&lt;/li&gt;
 &lt;li&gt;Difícil acceso al soporte&lt;/li&gt;
&lt;/ul&gt;&lt;br /&gt;
En resumen:&lt;code&gt;Los clientes no se sienten escuchados y 90% es problemas de comunicación&lt;/code&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Para mejorar la comunicación con los clientes&lt;/b&gt;&lt;br /&gt;
&lt;ol&gt; &lt;li&gt;Mantenerlo simple:saber bien que es lo que va a recibir/entregar que lo puedan  &quot;ver&quot;, muchos clientes son visuales existen otros requieren una explicación&lt;/li&gt;
 &lt;li&gt;Ser breve&lt;/li&gt;
 &lt;li&gt;No muy breve, sino que  sea efectiva: muchas veces el cliente no te  va a  decir lo  que no sabe,por ejemplo ciertos términos técnicos)&lt;/li&gt;
 &lt;li&gt;Eliminar  los tecnicismos&lt;/li&gt;
 &lt;li&gt;Evitar  el uso de abreviaciones y acrónimos&lt;/li&gt;
 &lt;li&gt;Ser concretos&lt;/li&gt;
 &lt;li&gt;Conversa de manera activa: tratar de hablar su mismo idioma&lt;/li&gt;
 &lt;li&gt;Escuchar de manera activa: realmente mostrar interés en la problemática del cliente&lt;/li&gt;
&lt;/ol&gt;</content><link rel='replies' type='application/atom+xml' href='http://pintoland.blogspot.com/feeds/8216036206781732353/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/1657736901030895703/8216036206781732353' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1657736901030895703/posts/default/8216036206781732353'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1657736901030895703/posts/default/8216036206781732353'/><link rel='alternate' type='text/html' href='http://pintoland.blogspot.com/2015/09/comunicacion-efectiva-con-clientes.html' title='Comunicación Efectiva Con clientes, inversionistas y las personas que nos rodean de Daniela Serrano'/><author><name>Fabián Pinto</name><uri>http://www.blogger.com/profile/03020316804062827481</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjjBT1cIyxpb3rWvPknQdrqXFPxQKVpc6Wre53OWSYByRw5C8IWvRHX3_B0IkuXPkZ8XKqCf3SoCac-wcQkZrrftE1jQyXHTM-wPddFglilI2iJIbYidRqLpPTKbqyAHIJhe8Xw37NL-iIXYUUxKnQy-pNrjV6LdRfwKW-_xaIKF6o/s220/321233897_3296355443911743_3463809348725319721_n.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1657736901030895703.post-4579344157635147348</id><published>2015-06-15T03:30:00.003-03:00</published><updated>2015-06-15T03:50:37.945-03:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="base64"/><category scheme="http://www.blogger.com/atom/ns#" term="ruby"/><title type='text'>Data Uri o Base64 a imagen en ruby</title><content type='html'>bueno  aqui voy a mostrar como hice para pasar una imagen que estaba  en base64 en ruby y se guardo como una foto&lt;br /&gt;
&lt;br /&gt;
&lt;pre class=&quot;brush:ruby&quot;&gt;require &#39;base64&#39;

def splitBase64(uri)
  if uri.match(%r{^data:(.*?);(.*?),(.*)$})
    return {
      :type =&gt;      $1, # &quot;image/jpg&quot;
      :encoder =&gt;   $2, # &quot;base64&quot;
      :data =&gt;      $3, # data string
      :extension =&gt; $1.split(&#39;/&#39;)[1] # &quot;jpg&quot;
      }
  end
end

def transf
    splitdata = splitBase64(data_url)
    data= splitdata[:data]
    File.open(&quot;/mifoto.jpg&quot;,&quot;wb&quot;) do |f|
    f.write(Base64.decode64(data))
    end
end
&lt;/pre&gt;&lt;br /&gt;
&lt;a href=&quot;http://dev-feeds.blogspot.com/2013/07/ruby-on-rails-convert-data-url-into.html&quot;&gt;fuente&lt;/a&gt;</content><link rel='replies' type='application/atom+xml' href='http://pintoland.blogspot.com/feeds/4579344157635147348/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/1657736901030895703/4579344157635147348' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1657736901030895703/posts/default/4579344157635147348'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1657736901030895703/posts/default/4579344157635147348'/><link rel='alternate' type='text/html' href='http://pintoland.blogspot.com/2015/06/data-uri-o-base64-imagen-en-ruby.html' title='Data Uri o Base64 a imagen en ruby'/><author><name>Fabián Pinto</name><uri>http://www.blogger.com/profile/03020316804062827481</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjjBT1cIyxpb3rWvPknQdrqXFPxQKVpc6Wre53OWSYByRw5C8IWvRHX3_B0IkuXPkZ8XKqCf3SoCac-wcQkZrrftE1jQyXHTM-wPddFglilI2iJIbYidRqLpPTKbqyAHIJhe8Xw37NL-iIXYUUxKnQy-pNrjV6LdRfwKW-_xaIKF6o/s220/321233897_3296355443911743_3463809348725319721_n.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1657736901030895703.post-4781301986512279593</id><published>2015-06-01T02:05:00.001-03:00</published><updated>2015-06-01T02:21:59.753-03:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="amazon"/><category scheme="http://www.blogger.com/atom/ns#" term="ruby"/><category scheme="http://www.blogger.com/atom/ns#" term="s3"/><category scheme="http://www.blogger.com/atom/ns#" term="script"/><title type='text'>Enviando archivos a S3 desde ruby</title><content type='html'>Hola hace tiempo que no escribía y eso es porque no he tenido ganas jaja sin embargo he aprendido muchas cosas últimos meses así que  por si las necesito usar vamos a anotarlo&lt;br /&gt;
&lt;br /&gt;
Existe al menos 3 gemas que podemos usar para esto  usemos  las oficiales de Amazon:&lt;br /&gt;
&lt;br /&gt;
AMAZON SDK V1&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;pre class=&quot;brush: ruby&quot;&gt;#!/usr/bin/env ruby

require &#39;aws-sdk-v1&#39;

#parametros AMAZON
region=&#39;us-east-1&#39;
accesskeyid=&#39;&amp;lt;mi_id&amp;gt;&#39;
accesskey=&#39;&amp;lt;mi_key&amp;gt;&#39;

#codigo
s3 = AWS::S3.new(:region=&gt;region,:access_key_id =&gt; accesskeyid,:secret_access_key =&gt; accesskey)
bucket = s3.buckets[&#39;&amp;lt;mi_bucket&amp;gt;&#39;]
data =&#39;&amp;lt;ruta&amp;gt;&#39;
type = &#39;imagen/png&#39;
extension = &#39;png&#39;
#nombre pseudo random
name = (&#39;a&#39;..&#39;z&#39;).to_a.shuffle[0..7].join + &quot;.#{extension}&quot;
obj = bucket.objects.create(name,data,{content_type:type,acl:&quot;public_read&quot;})
url = obj.public_url().to_s
&lt;/pre&gt;&lt;br /&gt;
&lt;br /&gt;
AMAZON V2&lt;br /&gt;
&lt;br /&gt;
&lt;pre class=&quot;brush: ruby&quot;&gt;#!/usr/bin/env ruby

require &#39;aws-sdk&#39;
require &#39;base64&#39;

#parametros
region=&#39;us-east-1&#39;
accesskeyid=&#39;&amp;lt;mi_id&amp;gt;&#39;
accesskey=&#39;&amp;lt;mi_key&amp;gt;&#39;

#codigo
s3=Aws::S3::Resource.new(:access_key_id =&gt; accesskeyid,:secret_access_key=&gt;accesskey,:region=&gt; region)
#recuperar base64
imagen=Base64.encode64(&#39;&amp;lt;ruta/archivo.jpg&amp;gt;&#39;)
data = Base64.decode64(imagen)

obj = s3.bucket(&#39;&amp;lt;mi_bucket&amp;gt;&#39;).object(&#39;&amp;lt;mi_nombre&amp;gt;&#39;).upload_file(data)
&lt;/pre&gt;</content><link rel='replies' type='application/atom+xml' href='http://pintoland.blogspot.com/feeds/4781301986512279593/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/1657736901030895703/4781301986512279593' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1657736901030895703/posts/default/4781301986512279593'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1657736901030895703/posts/default/4781301986512279593'/><link rel='alternate' type='text/html' href='http://pintoland.blogspot.com/2015/06/enviando-archivos-s3-desde-ruby.html' title='Enviando archivos a S3 desde ruby'/><author><name>Fabián Pinto</name><uri>http://www.blogger.com/profile/03020316804062827481</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjjBT1cIyxpb3rWvPknQdrqXFPxQKVpc6Wre53OWSYByRw5C8IWvRHX3_B0IkuXPkZ8XKqCf3SoCac-wcQkZrrftE1jQyXHTM-wPddFglilI2iJIbYidRqLpPTKbqyAHIJhe8Xw37NL-iIXYUUxKnQy-pNrjV6LdRfwKW-_xaIKF6o/s220/321233897_3296355443911743_3463809348725319721_n.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1657736901030895703.post-5990684684796030270</id><published>2015-02-09T19:51:00.001-03:00</published><updated>2015-02-09T19:53:04.484-03:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="javascript"/><category scheme="http://www.blogger.com/atom/ns#" term="js"/><title type='text'>funcion javascript puede devolver mas de un valor al mismo tiempo</title><content type='html'>Hace poquito estaba leyendo un poco de javascript y esto lo encontre igual simpatico veamos el ejemplo:&lt;br /&gt;
&lt;br /&gt;
&lt;pre class=&quot;brush:js&quot;&gt;function getSizes(width,height,depth){

      var area=width*height;
      var volumen=width*height*depth;
      var sizes=[area,volumen];
  return sizes;
}
&lt;/pre&gt;&lt;br /&gt;
Entonces obtendríamos los resultados asi:&lt;br /&gt;
&lt;br /&gt;
&lt;pre class=&quot;brush:js&quot;&gt;var areaOne=getSize(2,2,3)[0];
var volumenOne=getsize(2,2,3)[1];
&lt;/pre&gt;</content><link rel='replies' type='application/atom+xml' href='http://pintoland.blogspot.com/feeds/5990684684796030270/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/1657736901030895703/5990684684796030270' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1657736901030895703/posts/default/5990684684796030270'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1657736901030895703/posts/default/5990684684796030270'/><link rel='alternate' type='text/html' href='http://pintoland.blogspot.com/2015/02/funcion-javascript-puede-devolver-mas.html' title='funcion javascript puede devolver mas de un valor al mismo tiempo'/><author><name>Fabián Pinto</name><uri>http://www.blogger.com/profile/03020316804062827481</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjjBT1cIyxpb3rWvPknQdrqXFPxQKVpc6Wre53OWSYByRw5C8IWvRHX3_B0IkuXPkZ8XKqCf3SoCac-wcQkZrrftE1jQyXHTM-wPddFglilI2iJIbYidRqLpPTKbqyAHIJhe8Xw37NL-iIXYUUxKnQy-pNrjV6LdRfwKW-_xaIKF6o/s220/321233897_3296355443911743_3463809348725319721_n.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1657736901030895703.post-880272695495174527</id><published>2015-01-29T00:12:00.001-03:00</published><updated>2015-01-29T00:12:41.568-03:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="postgresql"/><category scheme="http://www.blogger.com/atom/ns#" term="SQL"/><title type='text'>Secuencias en postgresql</title><content type='html'>bueno como siempre ando molestando  y mas de un dolor de cabeza me  sucedido con las famosas secuencias en postgresql asi que dejare algunos comando para operar con alguna de estas cosas:&lt;br /&gt;
&lt;br /&gt;
La secuencia que se ocupara en estos ejemplos es &lt;code&gt;acos_id_seq&lt;/code&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Crear una secuencia&lt;/b&gt;&lt;br /&gt;
&lt;pre class=&quot;brush:sql&quot;&gt;CREATE SEQUENCE acos_id_seq START 1;
&lt;/pre&gt;&lt;br /&gt;
&lt;b&gt;Ver el ultimo valor usado en una secuencia&lt;/b&gt;&lt;br /&gt;
&lt;pre class=&quot;brush:sql&quot;&gt;SELECT last_value from acos_id_seq;
&lt;/pre&gt;&lt;br /&gt;
&lt;b&gt;Alterar el valor de la secuencia&lt;/b&gt;&lt;br /&gt;
&lt;pre class=&quot;brush:sql&quot;&gt;ALTER SEQUENCE acos_id_seq RESTART WITH 120;
&lt;/pre&gt;</content><link rel='replies' type='application/atom+xml' href='http://pintoland.blogspot.com/feeds/880272695495174527/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/1657736901030895703/880272695495174527' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1657736901030895703/posts/default/880272695495174527'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1657736901030895703/posts/default/880272695495174527'/><link rel='alternate' type='text/html' href='http://pintoland.blogspot.com/2015/01/secuencias-en-postgresql.html' title='Secuencias en postgresql'/><author><name>Fabián Pinto</name><uri>http://www.blogger.com/profile/03020316804062827481</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjjBT1cIyxpb3rWvPknQdrqXFPxQKVpc6Wre53OWSYByRw5C8IWvRHX3_B0IkuXPkZ8XKqCf3SoCac-wcQkZrrftE1jQyXHTM-wPddFglilI2iJIbYidRqLpPTKbqyAHIJhe8Xw37NL-iIXYUUxKnQy-pNrjV6LdRfwKW-_xaIKF6o/s220/321233897_3296355443911743_3463809348725319721_n.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1657736901030895703.post-3180726660121697455</id><published>2014-10-06T03:44:00.001-03:00</published><updated>2015-01-29T00:14:55.874-03:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="consola"/><category scheme="http://www.blogger.com/atom/ns#" term="lenguaje c"/><title type='text'>problema de la rana</title><content type='html'>Estaba aburrido y me coloque a revisar una demo de esto de pruebas de programador y pues hice el problema de la rana.&lt;br /&gt;
&lt;br /&gt;
una pequeña rana quiere llegar al otro lado del camina. la rana se encuentra en la posiciónX y quiere llegar a una distancia igual o mayor a &lt;code&gt;Y&lt;/code&gt;. la ramita solo puede saltar siempre una distancia &lt;code&gt;D&lt;/code&gt;.&lt;br /&gt;
&lt;br /&gt;
Se necesita contar el mínimo  numero de saltos  que necesita la rana para llegar a &lt;code&gt;Y&lt;/code&gt;. se necesita construir una función del tipo:&lt;br /&gt;
&lt;br /&gt;
&lt;pre class=&quot;brush:c&quot;&gt;int solution(int X, int Y, int D)&lt;/pre&gt;&lt;br /&gt;
Que dado tres números enteros &lt;code&gt;X&lt;/code&gt;,&lt;code&gt;Y&lt;/code&gt; y &lt;code&gt;D&lt;/code&gt; , retorne el mínimo numero de saltos hacia una distancia igual o mayor a &lt;code&gt;Y&lt;/code&gt;.&lt;br /&gt;
&lt;br /&gt;
Como ejemplo daban algo similar a esto:&lt;br /&gt;
&lt;br /&gt;
X = 25&lt;br /&gt;
Y = 100&lt;br /&gt;
D = 29&lt;br /&gt;
&lt;br /&gt;
La función retornaría 3 porque la ramita hace el siguiente proceso;&lt;br /&gt;
&lt;ul&gt;&lt;li style=&quot;list-style-type: square;&quot;&gt;primer salto queda en &lt;code&gt;(25 + 29)= 54&lt;/code&gt;&lt;/li&gt;
&lt;li style=&quot;list-style-type: square;&quot;&gt;segundo salto &lt;code&gt;(25 + 29 + 29) = 83&lt;/code&gt;&lt;/li&gt;
&lt;li style=&quot;list-style-type: square;&quot;&gt;tercer salto &lt;code&gt;(25 + 29 + 29 + 29) = 112&lt;/code&gt;&lt;/li&gt;
&lt;/ul&gt;Se asume que:&lt;br /&gt;
&lt;ul&gt;&lt;li style=&quot;list-style-type: square;&quot;&gt;&lt;code&gt;X&lt;/code&gt;, &lt;code&gt;Y&lt;/code&gt; y &lt;code&gt;D&lt;/code&gt; son enteros de rango desde  el 1 al 1.000.000.000&lt;/li&gt;
&lt;li style=&quot;list-style-type: square;&quot;&gt;&lt;code&gt;X ≤ Y&lt;/code&gt;&lt;/li&gt;
&lt;li style=&quot;list-style-type: square;&quot;&gt;La complejidad  debe ser de &lt;code&gt;O(1)&lt;/code&gt;&lt;/li&gt;
&lt;/ul&gt;&lt;br /&gt;
&lt;pre class=&quot;brush:c&quot; false=&quot;&quot; gutter:=&quot;&quot;&gt;#include &amp;lt;math.h&amp;gt;
#include &amp;lt;stdio.h&amp;gt;
#include &amp;lt;stdlib.h&amp;gt;

int salto(int x,int y,int d);
int main(int argc,char *argv[])
{
 printf(&quot;saltos :%i\n&quot;,salto(atoi(argv[1]),atoi(argv[2]),atoi(argv[3])));
 return 0;
}
/**Solucion**/
int salto(int x,int y,int d){
int div,mod;
div=(y-x)/d;
mod=(y-x)%d;
 if(0&amp;lt;mod)
 return (div+1);
 else
 return div;
}
&lt;/pre&gt;&lt;br /&gt;
Lo pueden compilar así &lt;code&gt;gcc -W saltos.c -o saltos&lt;/code&gt; y ejecutar &lt;code&gt;./saltos 25 100 29&lt;/code&gt;&lt;/code&gt;&lt;/code&gt;</content><link rel='replies' type='application/atom+xml' href='http://pintoland.blogspot.com/feeds/3180726660121697455/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/1657736901030895703/3180726660121697455' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1657736901030895703/posts/default/3180726660121697455'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1657736901030895703/posts/default/3180726660121697455'/><link rel='alternate' type='text/html' href='http://pintoland.blogspot.com/2014/10/problema-de-la-rana.html' title='problema de la rana'/><author><name>Fabián Pinto</name><uri>http://www.blogger.com/profile/03020316804062827481</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjjBT1cIyxpb3rWvPknQdrqXFPxQKVpc6Wre53OWSYByRw5C8IWvRHX3_B0IkuXPkZ8XKqCf3SoCac-wcQkZrrftE1jQyXHTM-wPddFglilI2iJIbYidRqLpPTKbqyAHIJhe8Xw37NL-iIXYUUxKnQy-pNrjV6LdRfwKW-_xaIKF6o/s220/321233897_3296355443911743_3463809348725319721_n.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1657736901030895703.post-4257848094786695133</id><published>2014-08-22T23:57:00.002-04:00</published><updated>2014-08-23T00:28:17.809-04:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="cakephp"/><category scheme="http://www.blogger.com/atom/ns#" term="php"/><title type='text'>Getting Post Data from the View adaptado para la versión 2.X</title><content type='html'>bueno he estado trabajando últimamente ya que en mi casa no me pueden ver sin hacer nada, he estado trabajando y aprendiendo sobre el framework llamado &lt;a href=&quot;http://cakephp.org/&quot; target=&quot;_blank&quot;&gt;Cakephp&lt;/a&gt; ya que se me encargo de hacer un sistema web,yo c quería usar PHP y no ruby on rails, revisando la literatura disponible, hay un ejemplo de un libro antiguo(2008 para mi ya es antiguo :p ) llamado &lt;code&gt;&quot;Cakephp Application Development&quot;&lt;/code&gt;, el código que sigue es el ejemplo:&lt;br /&gt;
&lt;br /&gt;
Se debe crear un controlador &lt;code&gt;users_controller.php&lt;/code&gt; con el siguiente código:&lt;br /&gt;
&lt;pre class=&quot;brush:php&quot; false=&quot;&quot; gutter:=&quot;&quot;&gt;&amp;lt;?php 
class UsersController extends AppController {
          var $name = &#39;Users&#39;;
          var $uses = array();
          function index() {
          if (!empty($this-&amp;gt;data)) {
          //data posted
          echo $this-&amp;gt;data[&#39;name&#39;];
          $this-&amp;gt;autoRender = false;
}}}
?&amp;gt;
&lt;/pre&gt;&lt;br /&gt;
la correspondiente vista en &lt;code&gt;/app/views/users/index.ctp&lt;/code&gt; con el siguiente código:&lt;br /&gt;
&lt;br /&gt;
&lt;pre class=&quot;brush:php&quot; false=&quot;&quot; gutter:=&quot;&quot;&gt;&amp;lt;php echo $form-&amp;gt;create(null, array(&#39;action&#39; =&amp;gt; &#39;index&#39;));?&amp;gt;
 &amp;lt;fieldset&amp;gt;
&amp;lt;legend&gt;Enter Your Name&amp;lt;/legend&amp;gt;
&amp;lt; echo $form-&amp;gt;input(&#39;name&#39;); ?&amp;gt;
&amp;lt;/fieldset&amp;gt;
&amp;lt;?php echo $form-&amp;gt;end(&#39;Go&#39;);?&amp;gt;
&lt;/pre&gt;&lt;br /&gt;
Todo eso funciona(supongo) en la versión 1.3  pero yo estoy usando la versión 2.x, después de averiguar un poco se puede hacer así:&lt;br /&gt;
&lt;br /&gt;
Creen un  controlador &lt;code&gt;/app/Controller/UsersController.php&lt;/code&gt; con el siguiente código:&lt;br /&gt;
&lt;br /&gt;
&lt;pre class=&quot;brush:php&quot; false=&quot;&quot; gutter:=&quot;&quot;&gt;&amp;lt;?php
class UsersController extends AppController {
var $name = &#39;t&#39;;
var $uses = array(&#39;t&#39;);
function index() {
         if (!empty($this-&amp;gt;request-&amp;gt;data)) {
         $this-&amp;gt;autoRender = false;
         $this-&amp;gt;layout = NULL;
         pr($this-&amp;gt;request-&amp;gt;data);
            }
         }
}?&amp;gt;
&lt;/pre&gt;&lt;br /&gt;
Creen una vista en &lt;code&gt;/app/View/Users/index.ctp&lt;/code&gt; con el siguiente form:&lt;br /&gt;
&lt;br /&gt;
&lt;pre class=&quot;brush:php&quot; false=&quot;&quot; gutter:=&quot;&quot;&gt;&amp;lt;?php echo $this-Form-&amp;gt;create(&#39;t&#39;, array(&#39;action&#39; =&amp;gt; &#39;index&#39;));?&amp;gt;
&amp;lt;fieldset&amp;gt;
&amp;lt;legend&amp;gt;Enter Your Name&amp;lt;/legend&amp;gt;
&amp;lt;?php echo $this-&amp;gt;Form-&amp;gt;input(&#39;name&#39;); ?&amp;gt;
&amp;lt;/fieldset&amp;gt;
&amp;lt;?php echo $this-&amp;gt;Form-&amp;gt;end(&#39;Go&#39;);?&amp;gt;
&lt;/pre&gt;&lt;br /&gt;
El &lt;code&gt;pr&lt;/code&gt; les va a mostrar el arreglo completo con la variable name y el valor ingresado, para que sirve esto pues  a mi no me sirvió para lo que quería pero si a alguien si le puede servir.&lt;br /&gt;
&lt;br /&gt;
&lt;a href=&quot;http://cakephp.1045679.n5.nabble.com/got-error-Error-Call-to-a-member-function-create-on-a-non-object-on-view-td5710491.html&quot; target=&quot;_blank&quot;&gt;fuente&lt;/a&gt;</content><link rel='replies' type='application/atom+xml' href='http://pintoland.blogspot.com/feeds/4257848094786695133/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/1657736901030895703/4257848094786695133' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1657736901030895703/posts/default/4257848094786695133'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1657736901030895703/posts/default/4257848094786695133'/><link rel='alternate' type='text/html' href='http://pintoland.blogspot.com/2014/08/getting-post-data-from-view-adaptado.html' title='Getting Post Data from the View adaptado para la versión 2.X'/><author><name>Fabián Pinto</name><uri>http://www.blogger.com/profile/03020316804062827481</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjjBT1cIyxpb3rWvPknQdrqXFPxQKVpc6Wre53OWSYByRw5C8IWvRHX3_B0IkuXPkZ8XKqCf3SoCac-wcQkZrrftE1jQyXHTM-wPddFglilI2iJIbYidRqLpPTKbqyAHIJhe8Xw37NL-iIXYUUxKnQy-pNrjV6LdRfwKW-_xaIKF6o/s220/321233897_3296355443911743_3463809348725319721_n.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1657736901030895703.post-2582964836779212036</id><published>2014-08-09T20:34:00.001-04:00</published><updated>2014-08-09T20:34:07.726-04:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="consola"/><category scheme="http://www.blogger.com/atom/ns#" term="mysql"/><title type='text'>Modificar el password de un usuario en Mysql</title><content type='html'>bueno estab haciendo algunas cosas y no se por que el mysql el password de un usuario que cree no se creo bien, así que obligado a cambiarlo, entramos usando el tipico &lt;code&gt;mysql -u root -p&lt;/code&gt; y luego:&lt;br /&gt;
&lt;pre class=&quot;brush:sql&quot;;gutter: false;&quot;&gt;UPDATE mysql.user SET Password=PASSWORD(&#39;Nuevo_Password&#39;) WHERE User=&#39;El_Usuario&#39; AND Host=&#39;Mi_host&#39;;
&lt;/pre&gt;&lt;br /&gt;
&lt;a href=&quot;http://www.cyberciti.biz/faq/mysql-change-user-password/&quot;&gt;fuente&lt;/a&gt;</content><link rel='replies' type='application/atom+xml' href='http://pintoland.blogspot.com/feeds/2582964836779212036/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/1657736901030895703/2582964836779212036' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1657736901030895703/posts/default/2582964836779212036'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1657736901030895703/posts/default/2582964836779212036'/><link rel='alternate' type='text/html' href='http://pintoland.blogspot.com/2014/08/modificar-el-password-de-un-usuario-en.html' title='Modificar el password de un usuario en Mysql'/><author><name>Fabián Pinto</name><uri>http://www.blogger.com/profile/03020316804062827481</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjjBT1cIyxpb3rWvPknQdrqXFPxQKVpc6Wre53OWSYByRw5C8IWvRHX3_B0IkuXPkZ8XKqCf3SoCac-wcQkZrrftE1jQyXHTM-wPddFglilI2iJIbYidRqLpPTKbqyAHIJhe8Xw37NL-iIXYUUxKnQy-pNrjV6LdRfwKW-_xaIKF6o/s220/321233897_3296355443911743_3463809348725319721_n.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1657736901030895703.post-9048228647857369244</id><published>2014-04-19T20:32:00.000-03:00</published><updated>2014-04-19T20:38:33.436-03:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="bash"/><category scheme="http://www.blogger.com/atom/ns#" term="consola"/><category scheme="http://www.blogger.com/atom/ns#" term="linux"/><title type='text'>usando wget para bajar de paginas con password</title><content type='html'>Pues hasta el momento esto es lo que he pillado para poder bajar de paginas que tienen que usar el usuario y password, respetando el nombre &amp;nbsp;que la misma pagina le da a los archivos.&lt;br /&gt;
&lt;br /&gt;
&lt;pre class=&quot;brush: bash;gutter: false;&quot;&gt;wget --auth-no-challenge --content-disposition --http-user=usuario --http-password=mi_pass -nc&lt;/pre&gt;</content><link rel='replies' type='application/atom+xml' href='http://pintoland.blogspot.com/feeds/9048228647857369244/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/1657736901030895703/9048228647857369244' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1657736901030895703/posts/default/9048228647857369244'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1657736901030895703/posts/default/9048228647857369244'/><link rel='alternate' type='text/html' href='http://pintoland.blogspot.com/2014/04/usando-wget-para-bajar-de-paginas-con.html' title='usando wget para bajar de paginas con password'/><author><name>Fabián Pinto</name><uri>http://www.blogger.com/profile/03020316804062827481</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjjBT1cIyxpb3rWvPknQdrqXFPxQKVpc6Wre53OWSYByRw5C8IWvRHX3_B0IkuXPkZ8XKqCf3SoCac-wcQkZrrftE1jQyXHTM-wPddFglilI2iJIbYidRqLpPTKbqyAHIJhe8Xw37NL-iIXYUUxKnQy-pNrjV6LdRfwKW-_xaIKF6o/s220/321233897_3296355443911743_3463809348725319721_n.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1657736901030895703.post-4218554758015580579</id><published>2014-04-15T10:35:00.002-03:00</published><updated>2014-04-15T10:36:11.877-03:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="consola"/><category scheme="http://www.blogger.com/atom/ns#" term="linux"/><category scheme="http://www.blogger.com/atom/ns#" term="USM"/><category scheme="http://www.blogger.com/atom/ns#" term="windows"/><title type='text'>Acceso tareas estructuras de datos USM</title><content type='html'>Bueno ya casi no voy a la universidad y el dia que me toco habian unos alumnos de segundo año que no tenian idea de como trabajar desde sus casas ya que no es necesario que instalen linux o una maquina virtual con linux&lt;br /&gt;
&lt;br /&gt;
Lo primero que quiero explicar es que les piden la tarea de estructuras de datos  en linux en el Laboratorio de informatica es por un asunto de tener una plataforma comun pero tambien es para que programen usando ANSI-C , es decir usen lo estandar y no usen librerias externas tipicas en windows.&lt;br /&gt;
&lt;br /&gt;
&lt;h3&gt;
Acceso SSH en windows&lt;/h3&gt;
&lt;br /&gt;
Lo que se necesita es un cliente ssh para poder entrar remotamente  lo pueden bajar &lt;a href=&quot;http://www.chiark.greenend.org.uk/~sgtatham/putty/download.html&quot; target=&quot;_blank&quot;&gt;aqui&lt;/a&gt;, al abrilo se peuden conectar por el momento(cada cierto tiempo cambia) ssh2.inf.utfsm.cl asi:&lt;br /&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjvcRkzLxjaooe8z6mh9Ra0bAJHU3PCgmRYh-YjEssbffXQPEYS7ojltubOZIiUa7PG8qUbwS8kfO3YnR_Chvt9u9i2ozX3hqynlB_RO0z78iVkWhD2t8IhznFSK7ztga_82tE-ra3GbqI/s1600/Captura1.PNG&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjvcRkzLxjaooe8z6mh9Ra0bAJHU3PCgmRYh-YjEssbffXQPEYS7ojltubOZIiUa7PG8qUbwS8kfO3YnR_Chvt9u9i2ozX3hqynlB_RO0z78iVkWhD2t8IhznFSK7ztga_82tE-ra3GbqI/s320/Captura1.PNG&quot; /&gt;&lt;/a&gt;&amp;nbsp;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
Pueden salvarla session y el puerto por defecto de ssh &amp;nbsp;es el 22 despues al dar &quot;open&quot; les va a solicitar el login el cual es del tipo &lt;code&gt;nombre.apellido&lt;/code&gt; y obviamente se password, ahora esta todo unificado, por lo tanto es lo mismo de su correo de informatica, moodle, la cuenta del lab.&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhz_itmizj1Xo9zOj9v1VuGQe_Q2Q8ozelOcxaWPKiMDQ5K9nnbUmWbtwMUx5sd_9L88dlOJ7WZt7bmLbjm6YbKjUimMmoquT3cGF8xQJoNvXOxmBdFyMFOGvr6iD5J3OlVEpqVLPPitC0/s1600/Captura2.PNG&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhz_itmizj1Xo9zOj9v1VuGQe_Q2Q8ozelOcxaWPKiMDQ5K9nnbUmWbtwMUx5sd_9L88dlOJ7WZt7bmLbjm6YbKjUimMmoquT3cGF8xQJoNvXOxmBdFyMFOGvr6iD5J3OlVEpqVLPPitC0/s1600/Captura2.PNG&quot; height=&quot;229&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
pues &amp;nbsp;presionan SI y deberia aparecer una tipica pantalla negra donde puedes escribir comandos :D&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgpPPdFGkfAga2-_Fs9tfbN4MB5IQPiY5mDNQrn62o0EvHbjtiOcoetFXU43T7JSkFsInuFFA150wvX_1cfJMKFWp6X0UhKsc2PIcSxhGq1xQkfB0P7-k_iJNKaTD64YABvolTK6RZDJNI/s1600/Captura3.PNG&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgpPPdFGkfAga2-_Fs9tfbN4MB5IQPiY5mDNQrn62o0EvHbjtiOcoetFXU43T7JSkFsInuFFA150wvX_1cfJMKFWp6X0UhKsc2PIcSxhGq1xQkfB0P7-k_iJNKaTD64YABvolTK6RZDJNI/s1600/Captura3.PNG&quot; height=&quot;201&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
&lt;/div&gt;
&lt;h3&gt;
Escribiendo la tarea&lt;/h3&gt;
Para escribir la tarea les recomendaria usar un editor de texto, uno que les parecera simpatico en windows y que les parsea o pinta las palabras propias del lenguaje es &lt;a href=&quot;http://notepad-plus-plus.org/&quot; target=&quot;_blank&quot;&gt;notepad++&lt;/a&gt; y subiral suando un cliente ftp, pero tambien existe la opcion de escribir directamente en la terminal usando &amp;nbsp;Nano y Vim.&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;usando nano&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
nano es un editor de texto en linux muy simple de usar basta con que escribamos algo como esto &lt;code&gt;nano ari1.c&lt;/code&gt; y mi tarea de ari se vera asi:&lt;br /&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjUJmho825diecdp_Hp-4Xyc8H9vAenyS7FL0ZIph8Xd9BibUsrWRQL-0TNKtc2IP8cCVI-1NiShXsP_jFPfn5wrs8Hrq6t0_PNOr1BBxIUCey3eg-kDRiNhe5yRAprdIDoncSln38yMLQ/s1600/nano.PNG&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjUJmho825diecdp_Hp-4Xyc8H9vAenyS7FL0ZIph8Xd9BibUsrWRQL-0TNKtc2IP8cCVI-1NiShXsP_jFPfn5wrs8Hrq6t0_PNOr1BBxIUCey3eg-kDRiNhe5yRAprdIDoncSln38yMLQ/s1600/nano.PNG&quot; height=&quot;236&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
Guardar: &lt;code&gt;Ctrl + o&lt;/code&gt;&lt;br /&gt;
Salir: &lt;code&gt;Ctrl+x&lt;/code&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;usando Vim&lt;/b&gt;&lt;br /&gt;
Vim es un poco mas complicado de usar, pero tiene la ventaja de que parcea los colores si detecta el tipo de archivo(tambien se le puede indicar que lenguaje estamos usando entonces podriamos hacer &lt;code&gt;vim ari1.c&lt;/code&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhb1G-johLm4EKe3QsEM-9nEBN6Gcv1g8cwIx9DdMlKhrIfGfTVc0IuwaANq1t3yF_vyF3sIffF_VUmm-Z-jSl7BJHY7-YEj2zsIeBg3MpQnWpzGx-kQjKg6D03p3_yITluPfl25aa5HXU/s1600/vim.PNG&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhb1G-johLm4EKe3QsEM-9nEBN6Gcv1g8cwIx9DdMlKhrIfGfTVc0IuwaANq1t3yF_vyF3sIffF_VUmm-Z-jSl7BJHY7-YEj2zsIeBg3MpQnWpzGx-kQjKg6D03p3_yITluPfl25aa5HXU/s1600/vim.PNG&quot; height=&quot;236&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
Se nota la diferencia sin embargo&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;ul&gt;
&lt;li&gt;guardar se hace escribiendo &lt;code&gt;:w&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;salir es &lt;code&gt;:q&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;forzar para salir &lt;code&gt;:!q&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;para poder escribir primero se presiona la letra &lt;code&gt;i&lt;/code&gt; y de ahi uno escribe&lt;/li&gt;
&lt;li&gt;si uno quiere ir a una linea especifica basta con que &amp;nbsp;uno escriba :numero_de_fila es decir si yo quiero ir a &amp;nbsp;la fila 64 escribo &lt;code&gt;:64&lt;/code&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;h3&gt;
Subiendo la tarea&lt;/h3&gt;
Para poder subir la tarea usando windows una forma es  usando un cliente ftp uno bastante conocido es el &lt;a href=&quot;https://filezilla-project.org/&quot; target=&quot;_blank&quot;&gt;Filezilla&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;ul&gt;
&lt;li&gt;host usamos:&lt;code&gt;ssh2.inf.utfsm.cl&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;login:&lt;code&gt;nombre.apellido&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;password:el  de su cuenta&lt;/li&gt;
&lt;li&gt;port: &lt;code&gt;22&lt;/code&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;br /&gt;
&lt;br /&gt;
Con estos datos  tendremos acceso a nuestro espacio  donde podemos subir el archivo con nuestro codigo&lt;br /&gt;
&lt;br /&gt;
&lt;h3&gt;
Compilando la Tarea&lt;/h3&gt;
Las tareas usualmente son en &lt;code&gt;C&lt;/code&gt; si lo queremos compilar recominedo hacer esto, por lo que  deben usar GCC los ayudantes descuentas por los warnings:&lt;br /&gt;
&lt;br /&gt;
&lt;code&gt;gcc -W Ejemplo.c -o Ejemplo&lt;/code&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;ul&gt;
&lt;li&gt;&lt;code&gt;Ejemplo.c&lt;/code&gt; es un archivo de texto plano que no es necesario que tenga al final el &lt;code&gt;.c&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;para darnos cuenta necesitamos incluir el flag &lt;code&gt;-W&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;Renombrar el archivo compilado &lt;code&gt;-o&lt;/code&gt; , si no renombramos el archivo lo mas probable es que nos salga un archivo &lt;code&gt;a.out&lt;/code&gt;.&lt;/li&gt;
&lt;/ul&gt;
&lt;br /&gt;
Ahora para ejecutarlo se deberia hacer asi:&lt;br /&gt;
&lt;br /&gt;
&lt;code&gt;fabian.pinto@ohiggins:$./Ejemplo&lt;/code&gt;&lt;br /&gt;
&lt;br /&gt;
Con lo cual se deberia ejecutar nuestro ejemplo&lt;br /&gt;
&lt;br /&gt;
PD: en todo caso cualquier duda preguntenle a los primos o algun estudiante decente &amp;nbsp;de 4 semestre hacia arriba.&lt;br /&gt;
&lt;a href=&quot;https://labcomp.inf.utfsm.cl/?p=153&quot; target=&quot;_blank&quot;&gt;Laboratorio de Computacion de Valpo&lt;/a&gt;</content><link rel='replies' type='application/atom+xml' href='http://pintoland.blogspot.com/feeds/4218554758015580579/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/1657736901030895703/4218554758015580579' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1657736901030895703/posts/default/4218554758015580579'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1657736901030895703/posts/default/4218554758015580579'/><link rel='alternate' type='text/html' href='http://pintoland.blogspot.com/2014/04/acceso-tareas-estructuras-de-datos-usm.html' title='Acceso tareas estructuras de datos USM'/><author><name>Fabián Pinto</name><uri>http://www.blogger.com/profile/03020316804062827481</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjjBT1cIyxpb3rWvPknQdrqXFPxQKVpc6Wre53OWSYByRw5C8IWvRHX3_B0IkuXPkZ8XKqCf3SoCac-wcQkZrrftE1jQyXHTM-wPddFglilI2iJIbYidRqLpPTKbqyAHIJhe8Xw37NL-iIXYUUxKnQy-pNrjV6LdRfwKW-_xaIKF6o/s220/321233897_3296355443911743_3463809348725319721_n.jpg'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjvcRkzLxjaooe8z6mh9Ra0bAJHU3PCgmRYh-YjEssbffXQPEYS7ojltubOZIiUa7PG8qUbwS8kfO3YnR_Chvt9u9i2ozX3hqynlB_RO0z78iVkWhD2t8IhznFSK7ztga_82tE-ra3GbqI/s72-c/Captura1.PNG" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1657736901030895703.post-4754189472304801655</id><published>2014-03-30T18:21:00.000-03:00</published><updated>2014-03-30T18:21:33.774-03:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="DOS"/><category scheme="http://www.blogger.com/atom/ns#" term="Splunk"/><title type='text'>Splunk Installer was unable to create Splunk Services</title><content type='html'>&lt;br /&gt;
si  reinstalando la aplicacion me salio el siguiente mensaje:&lt;br /&gt;
&lt;br /&gt;
&lt;code&gt;Splunk Installer was unable to create Splunk Services&lt;/code&gt;&lt;br /&gt;
&lt;br /&gt;
la solución al menos para mi fue aplicar el siguiente comando en D.o.S&lt;br /&gt;
&lt;br /&gt;
&lt;code&gt;sc delete splunkd&lt;/code&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;a href=&quot;http://answers.splunk.com/answers/73364/windows-msi-upgrade-fails-with-installer-unable-to-create-the-service&quot;&gt;fuente&lt;/a&gt;</content><link rel='replies' type='application/atom+xml' href='http://pintoland.blogspot.com/feeds/4754189472304801655/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/1657736901030895703/4754189472304801655' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1657736901030895703/posts/default/4754189472304801655'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1657736901030895703/posts/default/4754189472304801655'/><link rel='alternate' type='text/html' href='http://pintoland.blogspot.com/2014/03/splunk-installer-was-unable-to-create.html' title='Splunk Installer was unable to create Splunk Services'/><author><name>Fabián Pinto</name><uri>http://www.blogger.com/profile/03020316804062827481</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjjBT1cIyxpb3rWvPknQdrqXFPxQKVpc6Wre53OWSYByRw5C8IWvRHX3_B0IkuXPkZ8XKqCf3SoCac-wcQkZrrftE1jQyXHTM-wPddFglilI2iJIbYidRqLpPTKbqyAHIJhe8Xw37NL-iIXYUUxKnQy-pNrjV6LdRfwKW-_xaIKF6o/s220/321233897_3296355443911743_3463809348725319721_n.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1657736901030895703.post-4700766290601279561</id><published>2013-12-23T22:22:00.002-03:00</published><updated>2014-05-26T07:46:39.684-04:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="windows"/><category scheme="http://www.blogger.com/atom/ns#" term="windows 7"/><category scheme="http://www.blogger.com/atom/ns#" term="windows xp"/><title type='text'>se crean accesos directos en mi pendrive,disco duro, memoria flash etc etc etc</title><content type='html'>uff hace tiempo que no escribia nada pero como siempre que tengo algun problema  y encuentro la solucion trato de escribir.&lt;br /&gt;
&lt;br /&gt;
De partida existen mucho sobre esto pero encuentro que las respuestas estan mal enfocadas, vamos a tratar de cambiar esto&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Problema&lt;/b&gt;&lt;br /&gt;
al conectar mi pendrive en el computador de mi hermano pues mis carpetas desaparecieron y  solo aparecian los nombres de las carpetas, por esas ocurrencias de la vida pues se me ocurrio ver las propiedades de uno de las carpetas y vi un ruta muy extraña que decia algo asi:&lt;br /&gt;
&lt;br /&gt;
&lt;code&gt;F:\\wsyouhx videos&lt;/code&gt;&lt;br /&gt;
&lt;br /&gt;
Despues de buscar y solucionar al parecer eso lo mejor creo que es hacer esto&lt;br /&gt;
Solucion:&lt;br /&gt;
recomiendan escribir un comando con la consola  pero lo mas facil es crear un archivo comando.bat que lo ejecutamos en las zonas donde tengamos problemas,el codigo es el siguiente:&lt;br /&gt;
&lt;code&gt;@echo off&lt;br /&gt;
title=Desocultando archivos y carpetas!&lt;br /&gt;
cls&lt;br /&gt;
cd&lt;br /&gt;
echo Espere a Que esta ventana se cierre sola!&lt;br /&gt;
attrib /s /d -r -a -h -s&lt;br /&gt;
exit &lt;br /&gt;
&lt;/code&gt;&lt;br /&gt;
&lt;br /&gt;
se deja en la raiz de el disco o memoria flash y se le hace  click cuando se cierre solo la pantalla(se puede demorar si es un disco)&lt;br /&gt;
&lt;br /&gt;
buscan el nombre raro y lo eliminan, si es un disco el ejecutable lo pueden encontrar en &lt;code&gt;C:\\Documents and Settings\username\&lt;/code&gt;&lt;br /&gt;
&lt;br /&gt;
En el caso que sea un disco interno el del problema basta con que abran una pantalla de comando(solo simbolo de sistemas o en ejecutar escriban &lt;code&gt;cmd&lt;/code&gt;, y ejecutan el comando &lt;code&gt;tasklist&lt;/code&gt; busquen el nombre extraño y revisen el pid(id del proceso) y para matar el proceso que seguramente  usando interfaces no lo deje eliminar es usando el comando &lt;code&gt;tskill&lt;/code&gt;:&lt;br /&gt;
&lt;br /&gt;
ejemplo&lt;br /&gt;
&lt;code&gt;tskill 420&lt;/code&gt;&lt;br /&gt;
&lt;br /&gt;
después de eso pude tranquilamente borrar el ejecutable.&lt;br /&gt;
&lt;br /&gt;
ojo:existe el comando &lt;code&gt;taskkill&lt;/code&gt; pero sin embargo decia que mataba el proceso pero este seguia ahi &lt;br /&gt;
&lt;a href=&quot;http://processchecker.com/file/youbu.exe.html&quot;&gt;fuente&lt;/a&gt;</content><link rel='replies' type='application/atom+xml' href='http://pintoland.blogspot.com/feeds/4700766290601279561/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/1657736901030895703/4700766290601279561' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1657736901030895703/posts/default/4700766290601279561'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1657736901030895703/posts/default/4700766290601279561'/><link rel='alternate' type='text/html' href='http://pintoland.blogspot.com/2013/12/se-crean-accesos-directos-en-mi.html' title='se crean accesos directos en mi pendrive,disco duro, memoria flash etc etc etc'/><author><name>Fabián Pinto</name><uri>http://www.blogger.com/profile/03020316804062827481</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjjBT1cIyxpb3rWvPknQdrqXFPxQKVpc6Wre53OWSYByRw5C8IWvRHX3_B0IkuXPkZ8XKqCf3SoCac-wcQkZrrftE1jQyXHTM-wPddFglilI2iJIbYidRqLpPTKbqyAHIJhe8Xw37NL-iIXYUUxKnQy-pNrjV6LdRfwKW-_xaIKF6o/s220/321233897_3296355443911743_3463809348725319721_n.jpg'/></author><thr:total>0</thr:total></entry></feed>