<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Jonhnny Weslley</title>
    <description>The latest articles on DEV Community by Jonhnny Weslley (@jweslley).</description>
    <link>https://dev.to/jweslley</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F12415%2F13856.jpeg</url>
      <title>DEV Community: Jonhnny Weslley</title>
      <link>https://dev.to/jweslley</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/jweslley"/>
    <language>en</language>
    <item>
      <title>Como utilizar IA para aumentar sua produtividade em programação</title>
      <dc:creator>Jonhnny Weslley</dc:creator>
      <pubDate>Tue, 09 Jun 2020 10:38:09 +0000</pubDate>
      <link>https://dev.to/jweslley/como-utilizar-ia-para-aumentar-sua-produtividade-em-programacao-2jmn</link>
      <guid>https://dev.to/jweslley/como-utilizar-ia-para-aumentar-sua-produtividade-em-programacao-2jmn</guid>
      <description>&lt;p&gt;Nos últimos anos percebemos cada vez mais a utilização de inteligência artificial (IA) em nosso dia-a-dia. Porém, ainda temos poucas iniciativas visando utilizar IA para facilitar as atividades dos desenvolvedores. Como diz o velho ditado: "Casa de ferreiro, espeto de pau".&lt;/p&gt;

&lt;p&gt;Mas, aos poucos estas &lt;a href="https://www.codota.com"&gt;ferramentas&lt;/a&gt; &lt;a href="https://www.kite.com"&gt;vão&lt;/a&gt; &lt;a href="https://www.tabnine.com"&gt;aparecendo&lt;/a&gt;. Recentemente descobri o &lt;a href="https://www.tabnine.com"&gt;TabNine&lt;/a&gt; e comecei a usa-lo. Gostei tanto que resolvi escrever este post para compartilhar este achado.&lt;/p&gt;

&lt;p&gt;Basicamente, o TabNine é uma ferramenta de &lt;em&gt;code complete&lt;/em&gt; que utiliza rede neural para sugerir opções de código com base no contexto, algo semelhante às sugestões do Gmail.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--BtS6aLtB--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_66%2Cw_880/https://jonhnnyweslley.net/pt-br/blog/como-utilizar-ia-para-aumentar-sua-produtividade-em-programacao/tabnine_python_demo.gif" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--BtS6aLtB--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_66%2Cw_880/https://jonhnnyweslley.net/pt-br/blog/como-utilizar-ia-para-aumentar-sua-produtividade-em-programacao/tabnine_python_demo.gif" alt="Code complete de código Python. Fonte: TabNine blog"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Observe que as sugestões não se limitam apenas a palavras já digitadas ou métodos de um objeto, como geralmente é fornecido pela maioria dos editores. Isso porque o modelo de sugestão do TabNine foi treinado com aproxidamente &lt;a href="https://www.tabnine.com/blog/deep"&gt;2 milhões de arquivos&lt;/a&gt; do GitHub com o objetivo de prever as &lt;a href="https://github.com/openai/gpt-2"&gt;próximas palavras&lt;/a&gt; com base nas &lt;a href="https://openai.com/blog/better-language-models/"&gt;palavras anteriores&lt;/a&gt;. Como resultado, temos sugestões de trechos de códigos baseadas nas práticas mais comuns de projetos opensource utilizando o contexto do seu projeto.&lt;/p&gt;

&lt;h2&gt;
  
  
  Em quais editores posso utilizar?
&lt;/h2&gt;

&lt;p&gt;Utilizo TabNine com &lt;a href="https://github.com/jweslley/dotfiles/blob/b739dfbc9848b583757a53574bf3cba19bf3b8ce/.vimrc#L471"&gt;Vim (Coc)&lt;/a&gt;, mas ele também está disponivel para VS Code, IntelliJ Platform (IntelliJ IDEA, PyCharm, Android Studio, and others), Sublime Text, Vim, Vim (Deoplete), Emacs, Atom e Jupyter Notebook.&lt;/p&gt;

&lt;p&gt;Visite a &lt;a href="https://www.tabnine.com/install"&gt;documentação oficial&lt;/a&gt; para seguir as instruções de instalação para o seu editor preferido.&lt;/p&gt;

&lt;p&gt;Se o seu editor já fornece code complete utilizando &lt;a href="https://langserver.org/"&gt;Language Server Protocol&lt;/a&gt;, o TabNine pode &lt;a href="https://www.tabnine.com/semantic"&gt;integrar-se a ele&lt;/a&gt; para fazer as sugestões. O melhor de dois mundos. =)&lt;/p&gt;

&lt;h2&gt;
  
  
  Quais linguagens são suportadas?
&lt;/h2&gt;

&lt;p&gt;TabNine tem suporte a Python, JavaScript, Java, C++, C, PHP, Go, C#, Ruby, Objective-C, Rust, Swift, TypeScript, Haskell, OCaml, Scala, Kotlin, Perl, SQL, HTML, CSS, and Bash.&lt;/p&gt;

&lt;p&gt;Se você utiliza React, TabNine também é para você. Ele já reconhece os padrões mais comuns da biblioteca.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--7H4bdzMP--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_66%2Cw_880/https://jonhnnyweslley.net/pt-br/blog/como-utilizar-ia-para-aumentar-sua-produtividade-em-programacao/ghost_in_the_shell_programming.gif" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--7H4bdzMP--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_66%2Cw_880/https://jonhnnyweslley.net/pt-br/blog/como-utilizar-ia-para-aumentar-sua-produtividade-em-programacao/ghost_in_the_shell_programming.gif" alt="Como me sinto utilizando TabNine. Fonte: Ghost In The Sell"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Postado originalmente em &lt;a href="https://jonhnnyweslley.net/pt-br/blog/como-utilizar-ia-para-aumentar-sua-produtividade-em-programacao/"&gt;Jonhnny Weslley&lt;/a&gt;.&lt;/p&gt;

</description>
      <category>produtividade</category>
      <category>programacao</category>
    </item>
    <item>
      <title>How to rewrite git URLs to clone faster and push safer</title>
      <dc:creator>Jonhnny Weslley</dc:creator>
      <pubDate>Tue, 18 Sep 2018 00:00:00 +0000</pubDate>
      <link>https://dev.to/jweslley/how-to-rewrite-git-urls-to-clone-faster-and-push-safer-5apf</link>
      <guid>https://dev.to/jweslley/how-to-rewrite-git-urls-to-clone-faster-and-push-safer-5apf</guid>
      <description>&lt;p&gt;Whenever you wants to clone a git repository, you will take one of the following two options:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;visit the repository page in a browser, copy the repository url, go back to the terminal, type &lt;code&gt;git clone&lt;/code&gt; and paste the repository url.&lt;/li&gt;
&lt;li&gt;type the whole repository url by hand.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;I usually use the first one when browsing/exploring open source projects I find out there. But for personal/work projects is waste of time both of these options. I would say that for almost all personal/work repositories, the project name is the only part that changes in the repository URL. Thus, we can take advantage of a little-known git functionality: URL rewrite.&lt;/p&gt;

&lt;p&gt;With URL rewrite, you can use a different format for repository URLs. For example, instead of use this:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;git clone git@github.com:jweslley/dotfiles

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;You can use:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;git clone gh:dotfiles

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;To enable this URL rewrite you need to edit your global git config file (&lt;code&gt;~/.gitconfig&lt;/code&gt;) and add these lines:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;[url "git@github.com:jweslley/"]
  insteadOf = gh:

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;You also can add multiple URL rewrites. For example, I use one for GitHub and another for GitLab. For more information, check out my &lt;a href="https://github.com/jweslley/dotfiles/blob/e716c0122af2d6277ffaf3bde365838b61a5ea92/.gitconfig#L8-L12"&gt;~/.gitconfig&lt;/a&gt;.&lt;/p&gt;

&lt;h3&gt;
  
  
  Always push using SSH authentication
&lt;/h3&gt;

&lt;p&gt;Additionally, you are also able to rewrite URLs for push. This is useful when you want to guarantee you are using SSH authentication for pushes. For this, you can create a configuration section in &lt;code&gt;~/.gitconfig&lt;/code&gt; like:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;[url "git@github.com:"]
  pushInsteadOf = https://github.com/
  pushInsteadOf = git://github.com/

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This ensures that pushes will always use SSH authentication, even if the remote URL specifies &lt;code&gt;https://&lt;/code&gt; or &lt;code&gt;git://&lt;/code&gt;. For example, a URL like &lt;code&gt;https://github.com/jweslley/dotfiles.git&lt;/code&gt; will be rewritten to &lt;code&gt;git@github.com:jweslley/dotfiles&lt;/code&gt; for pushes, but pulls will still use the original URL.&lt;/p&gt;

&lt;p&gt;For more details, visit the official documentation:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;a href="https://git-scm.com/docs/git-clone"&gt;git-clone&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;
&lt;a href="https://git-scm.com/docs/git-push"&gt;git-push&lt;/a&gt;
&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--Ljjvrav2--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/http://feeds.feedburner.com/%257Er/JonhnnyWeslley/%257E4/mIwbmhZikwU" alt=""&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Originally posted &lt;a href="http://jonhnnyweslley.net/blog/how-to-rewrite-git-urls-to-clone-faster-and-push-safer/"&gt;here&lt;/a&gt;.&lt;/p&gt;

</description>
      <category>git</category>
    </item>
  </channel>
</rss>
