teleren/devto huggingface dataset:
Codewars Challenge: Opposite Number
Published: 2022-08-02 02:37:01

This is my approach to the 8kyu challenge labelled Opposite Number. This will be an explanation on how I approached the challenge and came to a solution.

The instructions for this challenge were given a number, find it's opposite. For example, 4 would return -4 , 88 would return -88 and 200.38 would return -200.38. The challenge provides the user a function called opposite which takes in a number parameter, as shown below.

```
function opposite(number){
/// your code here
}

```
Initial Approach
I first started by thinking of how I could turn the number that would be passed as an argument into a negative number or an opposite of itself. My initial attempt was to append the string "-" (minus sign) to number and then return it.

```
function opposite(number){
let newNum = "-" + number;
let oppNum = parseInt(newNum)
return oppNum;
}
```
The code snippet above had a few problems. One issue was that because of the use of the parseInt() method, decimals or floats wooul



d be rounded to the nearest integer e.g. 4.21 would be -4, instead of -4.21.
Final approach & solution
I then realized that I had to think of a way to get the opposite of number without appending any strings or special characters. I knew that in order to get the negative of the number, it would involve subtracting from number from another integer or vice versa. The only integer that would remain constant without changing itself or the argument, as well as guaranteeing that a negative number would be returned regardless of being an integer or float, was 0.

```
function opposite(number){
let oppNum = 0 - number
return oppNum;
}
```
ArgoCD Deleting an Application on Secret token Update
Published: 2022-08-02 02:31:54

Hi Friends,

Introduction

We need your expert guidance on one of the Argocd issues that we have faced on production recently. We have deployed Argocd on Openshift Version 4.8.43 cluster, where Argocd is running as containers. The version of Argocd is as below
                                                                                                                                       
  `argocd: v2.0.0-rc1+0ca643f
  BuildDate: 2021-03-19T21:27:59Z
  GitCommit: 0ca643f027b99e8a5b931bb8ee9df42c3e4b64bf
  GitTreeState: clean
  GoVersion: go1.16
  Compiler: gc
  Platform: linux/amd64`

Background about the issue

We are a Platform administration team where we deploy all infra related/Openshift cluster related changes via code using Github and argocd pushes it to the cluster after the PR is merged. The token on the Argocd expires on a monthly basis and as part of a Monthly activity we update the argocd token. We have been doing this for few months now without any issues but unfortunately for one production cluster the application within argocd(cpaas-tenants) got deleted. This has all the customer namespaces & containers defined within this application(cpaas-tenants) and due to this all Openshift namespaces on the cluster got deleted which caused an impact.

We have NOT explicitly provided any delete commands in CLI or selected a delete option in GUI. We are trying to assess how this could have happened. Appreciate if you can provide your inputs.

The following are the steps executed to renew the argocd token.

1. We got "`AVP_SECRET_ID`" from Vault

2. We took that secret ID and Applied on "argocd-vault-plugin-credentials" this secret file using Openshit GUI.

3. After Applied "`AVP_SECRET_ID`" on the secrets, we have restarted all argocd deployment pods which were running using below command.

   `oc delete <podname> -n <namespace>`
   Note: Namespace is the argocd namespace

4. To verify if the secret is applied on Openshift Cluster or not, we logged into argocd and checked the "Sync window" is healthy or not.

We had raised a case with Redhat who have suggested that argocd has excessive permissions which we are implementing a change to restrict Delete access. For now, we are trying to determine how the above steps to renew the token would have deleted the argocd application which in turn has got all the namespaces deleted.

Logs entries on Openshift.

`grpc.request.content="name:\"cpaas-tenants\" cascade:true propagationPolicy:\"foreground\" "
time="2022-07-28T09:55:48Z" level=info msg="bachamn deleted application" application=cpaas-tenants dest-namespace=default dest-server=https://kubernetes.default.svc reason=ResourceDeleted type=Normal`
[Desafio] - Função Recursiva
Published: 2022-08-02 02:19:16

> Conteúdo original [nesse tweet](https://twitter.com/zanfranceschi/status/1554289831425019904)

---

Ei dev,

Já ouviu falar de RECURSIVIDADE? Uma função recursiva é uma função que chama a si mesma e retorna quando alguma condição for verdadeira.

Tem coragem de implementar a função "dividir" da imagem abaixo e mostrar pra gente? 🤭

cc @sseraphini

![Image](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/v7ytiy0qo1xtc9t2x5p6.png)
Identifique e apague todas node_modules com NP Kill
Published: 2022-08-02 02:06:00

Eu sei, você trabalha com Javascript, e precisa de instalar variadas dependências. 
  O problema é que com o passar do tempo você se depara com vários projetos consumindo sua memória sem necessidade, pois precisamos do projeto vez ou outra, mas não do node_modules(a pasta mais pesada) necessariamente. 

O Npkill faz uma varredura em todo computador identificando as pastas node_modules e possibilita a exclusão ao pressionar [SPACE] 
via CLI.

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/do0l06p6fd6823cjw752.gif)
 

### Instalação
Você não precisa necessariamente instalar, pode simplesmente usar o comando abaixo
`npx kill
`
Ou caso quiser instalar
`npm i -g npkill
 #caso use Linux talvez precise utilizar sudo, cuidado.
`
Logo após 
`npkill
`

Referência:
https://www.npmjs.com/package/npkill
Late blooming and imposter syndrome
Tags: beginners, programming, discuss, career
Published: 2022-08-02 00:26:09

Hello everybody. I just joined the community and wanted to write a post of how I have been feeling lately. So I am a 30 year old junior dev I have been coding for a little over two years now. I was working as a forklift driver when I first started getting interested in ITu first interest was to get my ccna so I could work in the back of the warehouse wiring up server racks. After doing some research I discovered programming and decided it was something I wanted to do. That was over 5 years ago. As a single father I was stuck I couldn't afford to take off work to go to school and didn't have alot of free time bc I was working 6-7 days a week 10-12 hour shifts then had to take care of my kids by my self when I got home. I would constantly think about how much I wanted to make the switch. In a weird way covid was a blessing for me bc it enabled to be able to stay at home and take classes for software engineering. I signed up when I was 27 but classes didn't start until after my 28th birthday. Two years later I received my associates with honors. I started getting imposter syndrome because of my age. There is so much to learn and I wasted so much time.I thought I had a great base set of skills but then I started feeling like all my projects were not worth much more than a todo list after seeing younger peoples projects and skills. Then to make it worse job after job kept telling me no. Things are starting to look up now after getting an android internship then a offer for a Java dev. But I was wanting to know if anyone has a similar story to mine. It would make me feel better knowing there are others that started their programming career in their late 20's earlier 30's
[Desafio] - CRUD com uma Busca Legal :)
Published: 2022-08-02 00:10:00

> Conteúdo original [nesse tweet](https://twitter.com/zanfranceschi/status/1554257743518867461)

---

Ei dev iniciante,

Vamos dar um tapa nesse CRUD chatão aí que você fez?

Pega esse desafio:
Crie uma busca de apenas um campo no seu CRUD que busque em mais de uma coluna da tabela. É uma busca de um campo só!

Chega mais pra ver um exemplo.

cc @sseraphini

👇

![Image](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/d2trzaiho4wpxfasdh2c.png)

---

Por exemplo, em uma tabela como a de baixo, se o termo de busca for "joao", as linhas 1, 2 e 4 deveriam ser retornadas.

![Image](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/up71q669wu7aeq11jxy1.png)
As a gender queer/vegan developer's inconvenience who is assigned-sex is male
Tags: lgbtqia, twitter, feminism, veganism
Published: 2022-08-02 00:06:29

## 서론

트위터에서 프로그래머 계정을 운영하면서 종종 보는 트친소 해시태그가 있다. `#여성_개발자_트친소`. 아무래도 IT 산업이 남초이고, 여성 개발자들의 가시화나 연대가 필요하다고 생각되어, 만들어진 해시태그라고 생각한다. 그리고 그런 여성들의 연대가 필요하다고 생각한다. 그래서 `Women Techmakers`, `Women Who Code` 등 여성들을 위한 IT 컨퍼런스/커뮤니티가 그런 연대를 대변한다고 생각한다.

## 여성과만 교류해요

그리고 여성인 사람들과 교류하는 사람들도 종종 있다. 이건 트위터 내에서 다분히 많은 일인데, 아무래도 남성과 교류할 때 문제가 더 자주 일어날 확률이 높다는 점이나, 실제로 여럿 공론화되는 일들을 보면 남성이 여성에게 위해를 가하는 경우가 대부분이라는 점에서 공감할 수 있는 일이다. 

## 성소수자/비건으로

나는 성소수자이고, 논바이너리/젠더퀴어로 정의하고 있다. 그리고 지정성별은 남성이다. 지정성별이 남성인 나는 성별을 유추할 수 없게끔 만드는 프로필을 사용하는데, 그렇게 트위터 계정을 운영하다 보면 지정성별이 남성임을 드러낼 때가 어쩔 수 없이 생기게 된다. 그리고 불편한 일들이 생기게 된다. 사람들과의 관계에서 불편해진다. 

비거니즘을 드러낼 때도 불편한 일이 생긴다. 난 비건 지향이라고 했는데..

## 성소수자로서 불편했던 점

### 헤이조이스

제일 먼저 생각나는 것은 헤이조이스이다. 헤이조이스에 가입하는 로직에서, 여성임을 검증하는 데 주민등록번호를 사용한다. 여성들을 위한 서비스임을 알고 있고, 여성들을 위한 컨퍼런스를 만드는데 이런 방법이 제일 간단하다는 것을 알고 있다. 하지만 성별 정정이 되지 않은 트렌스젠더 여성은 사용할 수 없는 것인가? 지정성별이 여성인 사람만 가입해서 들을 수 있는 것인데, 이 점이 참 불편하게 느껴졌다.

### 여성전용

나는 발레도 좋아하고, 피아노도 좋아하고, 요가와 필라테스도 좋아하고, 폴댄스도 좋아하고, 옷도 여성복에서 사는 경우가 많다. 그리고 그것이 사회적으로 대한민국에서 어떤 이미지인지 알고 있다. 

대한민국에서 여성들이 주로 하는 운동을 참여하려고 하면 거절당하는 경우가 정말 많다. 운동할 때 입는 달라붙는 옷들을 보기 위해서 가는, 시선강간을 하기 위해서 가는 남자들이 많았을 것이고, 그래서 정작 하고 싶었던 나는 거절당했던 경우가 많다. 

여성복 코너에서 옷을 골라서 입어보려고 했는데, 여성전용 탈의실이어서 남성용 탈의실로 가야 하지를 않나.

트위터에서도 여성들과 소통하는 사람들이 있다. 내 젠더와 정체성을 미스젠더링하다가, 우연히 내 지정성별을 알게 되면 그제서야 거리를 두는. 그런 경우가 종종 있다.

이해는 하는데. 너무 속상하다.

## 비건 불편

### 논비건 트윗

이건 어쩔 수 없는 것 같다. 외국 개발자 트위터는 다를까? 난 비건인데, 개발자랑 소통하려고 하는데, 논비건 트윗이 엄청나게 올라온다. 개발자들이 모여서 스테이크 먹고, 논비건 레스토랑 돌아다니고. 그리고 종종 비거니즘에 대한 말도 안되는 비난이 올라오기도 한다.

대한민국, 특히 서울/판교/수도권 회사를 다니게 되면 지인들이 자연스럽게 생기고, 만나서 식사를 하고 또 트위터에서 그런 후기 사진을 올릴 수 있는 것은 자유고, 트위터 규정에 위배되는 것도 아니다. 하지만 비건 지향 개발자, 프로그래머로 살게 되면 이런 논비건 트윗에 익숙해지게 된다.

특히 고양이 사료 라던가, 동물권 관련 논란이라고 부르고 싶지 않지만, 그런 문제들에 대해 논쟁이 일어나면 정말 답답하다.

### 우마무스메

경마에 미소녀 애니메이션을 합쳐서 만들었다고는 하는데, 이것은 어떻게 받아들여야할까... 참 어려웠다. 애초에 동물권 자체를 이해하지 않고 이해하지 않으려 하는 사람들에게 어떻게 설명할 수 있을까? 경마가 동물 학대이며, 폐지해야하는데, 경마를 폐지하면 불법 도박이 흥해서 안된다니. 동물의 권리 자체에는 인지를 못하는 사람들인데.. 세상 사람들에게 너무 많은 것을 바라는 것 같다.

## 기타

### 회사

성소수자, 페미니즘, 비거니즘 등의 정체성, 가치관을 가지고 있는 나에게 불편한 회사들이 많다. 

대표적으로 OPGG의 경우 내가 가고싶어서 회사에 이메일도 보내서 오피스를 방문했던 적도 있는데, 페미니즘을 접하고 난 이후 자체 커뮤니티에서 여성혐오, 성소수자 혐오 게시글들에 대한 방치를 보고서 정말 어이가 없었다. 심지어 리그 오브 레전드의 성소수자 캐릭터나 pride month에 대한 글들을 보면 커뮤니티에 대한 방치인 것 같다.

정육각 같이 논비건 아이템으로 회사를 운영하는 것도 불편하고.

비건/페미니즘/인권/장애인 차별/성소수자 혐오 혹은 과한 수수료/시장 장악 등의 행보를 보인 기업들이 꾸준히 눈에 보이고 스트레스를 정말 많이 받는다.

난 한국을 떠야하는 것 같다.

## 총평

그렇게 불편했던 점들에 대해 와르르 쏟아내보았다. 이런 내용에 대해 공감할 사람들이 얼마나 있을까? 모르겠다. 그들은 이 글을 볼 일도 없을 것이고, "그럴 수 있겠구나" 하고 고기 먹으러 가겠지. 우유(소젖) 라떼 먹으러 가겠지?

성소수자, 페미니즘, 비거니즘 등을 접하고 세상의 불합리함을 더욱 알게 되었는데, 내가 할 수 있는 것이 이 세상에 대한 영향력을 늘리는 것이라면, 어떻게 할 수 있을까 고민이 된다. 개발자로서 어떤 프로덕트를 만들고, 결국 정치나 세상이나 여론을 바꿀 수 있을지, 고민을 많이 하게된다. 결국 내 목표는 정치적일 수 밖에 없다.
🔊🎉 Announcing Automation Hacks YouTube Channel 🌱
Tags: announcements, youtube
Published: 2022-08-14 09:40:05

---
title: 🔊🎉 Announcing Automation Hacks YouTube Channel 🌱
published: true
date: 2022-08-02 00:00:00 UTC
tags: Announcements,Announcements,YouTube
canonical_url: https://automationhacks.io/2022-08-02-automation-hacks-youtube-channel
---

![Automation hacks YouTube channel](https://automationhacks.io/assets/images/2022/08/automation-hacks-you-tube.png)
_Day 1: automation hacks on YouTube_

Hello, all the wonderful Testers and Developers out there! 👋🏼

Today, I’m announcing the launch of my YouTube channel 📺 on “Software Engineering and Testing” 🌱

What’s it called, you ask? 😮

Of course, it’s named **“automation hacks”** 🧑🏻‍💻

Excited to check it out?

Head on over to [automation hacks](https://www.youtube.com/channel/UC-KAka-3EgsbF1kekh_uYJw)

## First series on Espresso

I’ll start with a series on **Android Espresso** wherein we will understand all the nitty gritty details of this wonderful framework, The first video is already out:

[Hello Espresso: Introduction to Espresso](https://www.youtube.com/watch?v=lZ8Yx0Azx_A)

To avoid the perfection trap, I’m shipping the 0.1 version right away. This channel is going to iterate and evolve hopefully with your love and constructive comments and feedback.

## What topics will I cover in this channel? 💪🏼

- Software Testing
- Test Automation
- Programming languages
- Tooling and Infrastructure
- Software Engineering
- Quality culture principles, patterns, and my observations

Some of the videos might be inspired by my earlier blogs on[automationhacks.io/](https://automationhacks.io/) or my newsletter[newsletter.automationhacks.io/](https://newsletter.automationhacks.io/)

## Now for the much-awaited YouTube plug. 😊

- Please subscribe and tap on the bell to get notified when a new video is out
- If the content is useful to you, Do like it to show your appreciation
- If not, Please take a couple of minutes to give honest and constructive feedback so that this could improve.
Local .NET MAUI events happening around the world!
Tags: dotnet, dotnetmaui, csharp, eventsinyourcity
Published: 2022-08-01 23:01:20

[.NET MAUI](http://dot.net/maui) is finally here! With .NET MAUI you can build native, cross-platform desktop and mobile apps from a single C# codebase.  To celebrate, we are collaborating with community members around the globe through local in-person (and online) .NET MAUI events and meetups. Join Microsoft team members and the community to hear all about .NET MAUI and learn how you can create your first .NET MAUI project.

Each event will event will kick off with an introduction to .NET MAUI run by a .NET expert. This session will announce the launch of .NET MAUI, product roadmap, an introduction into the architecture, and live code demos. The introduction will be followed by a workshop where you can start to build your very first multi-platform app with .NET MAUI.



![Reactor Events](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/3fqaujtg4804sr570etl.png)


FREE Pizza will be provided at some locations! 🍕 

## When & Where
This event is running in multiple cities throughout August and September. Register for an event in
- **August 22**: Redmond, WA, USA 
- **August 25**: San Francisco, CA, USA 
- **August 27**: Bengaluru, India
- **August 27**: Sydney, Australia 
- **September**: London, UK
- **September**: Tel Aviv, Israel

**And more!** Check out the updated list of events here: [.NET MAUI @ Microsoft Reactor](https://docs.microsoft.com/events/learntv/reactor-netmaui-2022/)


Each event will be live streamed, so you can [tune in ONLINE](https://docs.microsoft.com/events/learntv/reactor-netmaui-2022/)!



## What
Come learn something new and leave with something that we all built, together, live with experts. The agenda will vary location by location but here is what can expect: 
1. Introduction: What is .NET MAUI? What does the architecture look like? And, what is the product roadmap? Come find out! 
2. Workshop
3. Q&A: Get all your .NET MAUI questions answered!

## RSVP Today
Go to our [Registration Page](https://docs.microsoft.com/events/learntv/reactor-netmaui-2022/) to find an event near you!

## Looking for more .NET MAUI?
- [Find or host a .NET MAUI Meetup](https://devblogs.microsoft.com/dotnet/announcing-dotnet-maui-focus-reactor-community-events/#host-your-own-virtual-and-in-person-events) 
- Don't forget to check out the [.NET Conf: Focus on MAUI Focus](https://focus.dotnetconf.net/) event on August 9th 
- Start a self-guided [.NET MAUI learning path](https://docs.microsoft.com/learn/paths/build-apps-with-dotnet-maui/)
- Watch the [.NET MAUI beginner videos series](https://www.youtube.com/playlist?list=PLdo4fOcmZ0oUBAdL2NwBpDs32zwGqb9DY)
How to use VS Code Multi-Cursor Editing
Published: 2022-08-01 22:52:44

In this video we will learn how to use a powerful feature in VSCode: multi-cursor editing. Multi-cursor editing is used to edit several lines of code at a time. Learn this powerful feature to edit code files faster.

There are a few way to activate multi-cursor editing 

There are a few way to activate multi cursor editing 

For a Mac
⌘D  - Add selection to next Find match
⇧⌘L -  Select all occurrences of current selection
⌥ + - click Insert cursor
⌥⌘↑ - Insert cursor above
⌥⌘↓  - Insert cursor below

For Windows
Ctrl+D - Add selection to next Find match
Ctrl+Shift+L -  Select all occurrences of current selection
Ctrl+Alt+ ↑ / ↓ - Insert cursor above / below

VSCode Cheat sheet for Mac OS
https://code.visualstudio.com/shortcuts/keyboard-shortcuts-macos.pdf

VSCode Cheat Sheet for Windows
https://code.visualstudio.com/shortcuts/keyboard-shortcuts-windows.pdf

Check out this short video:

{% embed https://www.youtube.com/shorts/vJvF7Y9oEjc %}
Day 114: Hello Frontend Mentor
Published: 2022-08-01 22:44:47

Hi!
This marks the start of doing Frontend Mentor challenges and I was able to solve a simple one and learned about some new CSS concepts including variables and box-sixing property. I have known Frontend Mentor for a while and I knew their challenges are a great way to practice and enhance css and frontend development skills but I always had excuses for actually doing any challenge but today I spared some time to go through one challenge and I hope I will be able to do more from now on. Generally today I focused on Flutter and there was more things to download before I can start building something but I guess I know have the setup ready and have looked into the basics of Dart which is a programming language that Flutter uses so I can now get started building by tomorrow 

Tomorrow I won't do much coding but I will continue lookin into Flutter and see what I will be able to Learn

Signing off...
Hello world with Spring Boot and Docker
Published: 2022-08-01 22:35:00

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/nonhn6j0z3bmw27zlt1w.png)
 
This is a small example of how to create a Docker container using Spring boot.

Here we go ...

1. Create new Spring boot App [spring initializr](https://start.spring.io/) dependencies (spring web)

2. Create new class HelloWorldController.java

```
@RestController
@RequestMapping("/api/v1/hello-world")
public class HelloWorldController {
    @GetMapping()
    public String getHelloWorld(){
        return "Hello everyone from Spring Boot App";
    }
}
```

3. Build jar file with maven 

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/bi0js8fvya2s4tkrjl1r.png)
 
4. Create Dockerfile in project root

```
FROM openjdk:11
ADD target/demo-hello-0.0.1-SNAPSHOT.jar demo-hello.jar
EXPOSE 8090
ENTRYPOINT ["java", "-jar", "demo-hello.jar"]
```

5. Generate imagen

`>docker build -t image_hello .`

6. Generate container 

`> docker run --name hello_container -p 9000:8080 image_hello`

7. Test 

[localhost](http://localhost:9000/api/v1/hello-world)

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/i4xoql50isezuxd3hjj7.png)
 

Thank you so much for reading my post
Why C for every Dev
Tags: beginners, programming, discuss
Published: 2022-08-01 22:16:00

**C** is a `middle` level programming language that interfaces the **lower** level and the **higher** level aspects. It introduces the important fundamentals of Computer Science that every Dev should know including: 

---

1. **Computer Architectures** as in _how the CPU works_ during memory allocation at runtime. It gives one the power to control the hardware. The computer doing what you want and when you want it.

2. **Compiler design and Construction**
C Introduces various aspects of compiler design including _symbols, tokens and lookup tables when learning the compilation process of any C program at different stages. Essentially compiler design should be taught in C.

3. **Faster Execution Time**
C is weakedly fast as it lacks additional overhead processing including garbage collection as in _python_, a problem left for the programmer to take care of.

4. **Embedded Programming**
Every aspiring to robotics students should start with C as it's used in kernel design and the operating systems development, and micro controller programming.

5. **Problem solving**
C programming language has fewer libraries in comparison with other high-level languages. So, learning C programming also clears programming concepts to a great extent as you have to write lot of things from scratch. You will not be dependent on the programming language entirely for implementing some basic operations and implementing them on your own will also help you to build your analytical skills

---
Additional sources... [GeeksforGeeks](https://www.google.com/amp/s/www.geeksforgeeks.org/why-learning-c-programming-is-a-must/amp/)
Compilar una aplicación Java 7 en un pipeline
Tags: ci, java, azure, devops
Published: 2022-08-01 22:15:00

Puede que no sea el caso para la mayoría de los proyectos, pero si tu aplicación depende de un S.O. de 32 bits; es imposible actualizar la versión de Java.

Ello no impide automatizar la construcción, mediante un _Pipeline_ de **Azure**.

---
Los aspectos a tener en cuenta:

1. Proveer las herramientas necesarias
  - JDK 1.7
  - Ant 1.19
1. Instalar y configurar previo a la compilación

Lo recomendable es no agregar estos binarios en el propio _source code_. Por esa razón (y facilidad al usar **GIT**) se creo un repositorio que contiene los archivos necesarios.

https://gitlab.com/edgar.gs/posunificado-build-java7.git

El archivo azure-pipeline.yml luce de esta forma:
```yaml
# Ant
# Build your Java projects and run tests with Apache Ant.
# Add steps that save build artifacts and more:
# https://docs.microsoft.com/azure/devops/pipelines/languages/java

trigger:
- master

pool:
  vmImage: windows-latest

steps:
- script: |
    git clone https://gitlab.com/edgar.gs/posunificado-build-java7.git
- task: CopyFiles@2
  inputs:
    SourceFolder: 'posunificado-build-java7/build/jre7/lib/'
    Contents: '*.jar'
    TargetFolder: 'C:\jre7\lib'    
- task: JavaToolInstaller@0
  inputs:
    versionSpec: '7'
    jdkArchitectureOption: 'x86'
    jdkSourceOption: LocalStorage
    jdkFile: 'posunificado-build-java7/build/jdk1.7.0_65.7z'
    jdkDestinationDirectory: '$(agent.toolsDirectory)/jdk7'
    cleanDestinationDirectory: false
- task: ExtractFiles@1
  inputs:
    archiveFilePatterns: 'posunificado-build-java7\build\apache-ant-1.9.16-bin.zip'
    #destinationFolder:
    cleanDestinationFolder: false
    overwriteExistingFiles: false    
- task: Ant@1
  inputs:
    antHomeDirectory: 'apache-ant-1.9.16'
    workingDirectory: ''
    buildFile: 'fps-app-ws-posunificado/build-azure.xml'
    javaHomeOption: 'JDKVersion'
    jdkVersionOption: '1.7'
    jdkArchitectureOption: 'x86'
    publishJUnitResults: false
    #testResultsFiles: '**/TEST-*.xml'
- task: CopyFiles@2
  inputs:
    contents: 'fps-app-ws-posunificado/deploy/**'
    targetFolder: $(Build.ArtifactStagingDirectory)
- task: PublishBuildArtifacts@1
  inputs:
    pathToPublish: $(Build.ArtifactStagingDirectory)
    artifactName: MyBuildOutputs
```
---

Se puede observar la ejecución en el siguiente video:

{% embed https://youtu.be/nfr2Kb5C52E %}

---

## Documentación


https://docs.microsoft.com/en-us/azure/devops/pipelines/tasks/tool/java-tool-installer?view=azure-devops
https://docs.microsoft.com/en-us/azure/devops/pipelines/tasks/build/ant?view=azure-devops