Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
3 changes: 3 additions & 0 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
"python.pythonPath": "C:\\Users\\luism\\anaconda3\\python.exe"
}
110 changes: 65 additions & 45 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,45 +1,65 @@
# PROJETO DE SELEÇÃO

Ao conhecer uma pessoa que está aplicando para a Magrathea gostamos de ter uma conversa sobre código. Afinal, escrever, ler e discutir sobre código faz parte da nossa rotina diária de trabalho.

Você pode implementar o projeto usando qualquer linguagem de sua preferência. Lembre-se: use a linguagem com a qual você tem mais familiaridade.

## O QUE VAMOS AVALIAR

Queremos avaliar sua capacidade de fornecer um produto simples com documentação suficiente para outros desenvolvedores contribuírem ativamente para o projeto posteriormente. Na entrevista vamos prestar atenção nos seguintes itens:

* Comunicação na revisão do código presencial;
* Argumentos sobre desafios enfrentados e escolhas realizadas na implementação;

Ao revisar seu código vamos prestar atenção nos seguintes itens:

* Organização do código;
* Código bem escrito, limpo e coeso;
* Arquitetura e princípios de desenvolvimento;
* Documentação (README.md) com instruções claras para reproduzir o projeto;
* Uso adequado de versionamento do código em git;
* Uso de testes automatizados;
* Deploy da aplicação: recomendamos Heroku por ter plano free;
* O design da API RESTful é implementado, usando corretamente os verbos HTTP e o código de status apropriado;
* Uso adequado de HTML5, CSS3 e JavaScript em um front-end minimamente estruturado.

Caso você não se sinta confortável com algum desses itens, tudo bem, apenas nos fale sobre isso, ok? O objetivo aqui não é você programar de graça para nós, nem te fazer perder tempo com algo irrelevante. Nosso objetivo aqui é ter um código sobre o qual podemos conversar. Como você deve ter notado, a gente preza muito por colaboração, trabalho em time e comunicação. O objetivo aqui é ter, minimamente, essa experiência com você.

Respeite o seu nível de conhecimento e experiência, o importante é você saber dizer o motivo das suas escolhas. Se você tiver qualquer dúvida, por favor, entre em contato com a gente. Se quiser uma revisão no seu código em um Pull Request no Github, pode nos chamar. Estamos disponíveis para te ajudar a finalizar esse processo.
Ah, por último. Você acha que consegue nos responder em quanto tempo? Duas semanas é ok para você?

## IDEIAS DE PROJETOS

A seguir seguem algumas ideias de projetos que você pode implementar:

* [Cliente para o GitHub](https://github.com/magrathealabs/template-projeto-selecao/blob/master/projects/GITHUB.md);
* [Cliente para o Twitter](https://github.com/magrathealabs/template-projeto-selecao/blob/master/projects/TWITTER.md);
* [Cliente para o Meetup](https://github.com/magrathealabs/template-projeto-selecao/blob/master/projects/MEETUP.md).

Tem alguma outra ideia? Tem algum projeto que já está pronto e gostaria de apresentar? Fale com a gente :)

## COMO COMPARTILHAR O PROJETO CONOSCO

1. Apague este README.md e adicione informações que achar relevante como configurar o projeto, contendo os comandos que devem ser executados para executar ele e os testes;
2. Abra um PR apontando para a branch master deste repositório;
3. Escreva qualquer consideração na descrição do PR e faça qualquer comentário que achar pertinente no código.
# Repo-Manager
Projeto para seleção de estágio da Magrathea Labs.

## Funcionalidade

- Cadastro de conta com Github
- Captura de nome a registro com Github


### Administraçao de tags
1. Adiçao
2. Remoçao
3. Edicao

- Busca por tags
- Controla tags repetidas para um repositório

<br />

### Status do projeto: **Em desenvolvimento**

<br />

#### Desenvolvimentos seguintes:
- Interface mais user-friendly
- Melhoria na estruturaçao do banco de dados

<br />

### Deploy da Aplicação com Hukoru:

> https://django-repo-manager.herokuapp.com/

<br />

### Construido com:
- Django 3.1.5
- SQLite
- Coverage para testes

<br />

### Instalacao:

- -git clone https://github.com/luismomm2110/repo-manager
- cd repo-manager
- python manage.py runserver

<br />

<img src= "https://scontent.fjoi2-1.fna.fbcdn.net/v/t1.0-9/145439713_3928870463824690_9102559612396937847_o.jpg?_nc_cat=110&ccb=2&_nc_sid=730e14&_nc_ohc=_yZ2cBFini8AX8L-HZi&_nc_ht=scontent.fjoi2-1.fna&oh=b81dfd2bf1f048d04e73be11eff9d9cd&oe=60425E2C " >

*exemplo de tela inicial com tags inseridas e busca por uma delas*

### Testes

<br />

- python manage.py test

- python manage.py test network.tests.test_views

- - *especifico para Views. O nome do usuario pode ser mudado em IndexTestCase para certificar que carrega os repositorios favoritados usando force_login*

- python manage.py test network.tests.test_models
Binary file added db.sqlite3
Binary file not shown.
Empty file added django_social_app/__init__.py
Empty file.
Binary file not shown.
Binary file added django_social_app/__pycache__/tests.cpython-39.pyc
Binary file not shown.
3 changes: 3 additions & 0 deletions django_social_app/admin.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
from django.contrib import admin

# Register your models here.
5 changes: 5 additions & 0 deletions django_social_app/apps.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
from django.apps import AppConfig


class DjangoSocialAppConfig(AppConfig):
name = 'django_social_app'
Empty file.
Binary file not shown.
3 changes: 3 additions & 0 deletions django_social_app/models.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
from django.db import models

# Create your models here.
3 changes: 3 additions & 0 deletions django_social_app/tests.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
from django.test import TestCase

# Create your tests here.
3 changes: 3 additions & 0 deletions django_social_app/views.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
from django.shortcuts import render

# Create your views here.
1 change: 1 addition & 0 deletions filename.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
some-text
21 changes: 21 additions & 0 deletions manage.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
#!/usr/bin/env python
"""Django's command-line utility for administrative tasks."""
import os
import sys


def main():
os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'project4.settings')
try:
from django.core.management import execute_from_command_line
except ImportError as exc:
raise ImportError(
"Couldn't import Django. Are you sure it's installed and "
"available on your PYTHONPATH environment variable? Did you "
"forget to activate a virtual environment?"
) from exc
execute_from_command_line(sys.argv)


if __name__ == '__main__':
main()
Empty file added network/__init__.py
Empty file.
Binary file added network/__pycache__/__init__.cpython-39.pyc
Binary file not shown.
Binary file added network/__pycache__/admin.cpython-39.pyc
Binary file not shown.
Binary file added network/__pycache__/forms.cpython-39.pyc
Binary file not shown.
Binary file added network/__pycache__/models.cpython-39.pyc
Binary file not shown.
Binary file added network/__pycache__/tests.cpython-39.pyc
Binary file not shown.
Binary file added network/__pycache__/urls.cpython-39.pyc
Binary file not shown.
Binary file added network/__pycache__/views.cpython-39.pyc
Binary file not shown.
22 changes: 22 additions & 0 deletions network/admin.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
from django.contrib import admin

from .models import Tag, Repo, User

# Register your models here.

admin.site.register(Tag)
admin.site.register(Repo)
admin.site.register(User)













5 changes: 5 additions & 0 deletions network/apps.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
from django.apps import AppConfig


class NetworkConfig(AppConfig):
name = 'network'
14 changes: 14 additions & 0 deletions network/forms.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
from django.forms import ModelForm
from network.models import Tag, Repo, User
from django import forms

class RepoForm(ModelForm):
class Meta:
model = Tag
fields = ['name']


class EditForm(ModelForm):
class Meta:
model = Tag
fields = ['name']
44 changes: 44 additions & 0 deletions network/migrations/0001_initial.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
# Generated by Django 3.1.5 on 2021-01-29 11:34

import django.contrib.auth.models
import django.contrib.auth.validators
from django.db import migrations, models
import django.utils.timezone


class Migration(migrations.Migration):

initial = True

dependencies = [
('auth', '0012_alter_user_first_name_max_length'),
]

operations = [
migrations.CreateModel(
name='User',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('password', models.CharField(max_length=128, verbose_name='password')),
('last_login', models.DateTimeField(blank=True, null=True, verbose_name='last login')),
('is_superuser', models.BooleanField(default=False, help_text='Designates that this user has all permissions without explicitly assigning them.', verbose_name='superuser status')),
('username', models.CharField(error_messages={'unique': 'A user with that username already exists.'}, help_text='Required. 150 characters or fewer. Letters, digits and @/./+/-/_ only.', max_length=150, unique=True, validators=[django.contrib.auth.validators.UnicodeUsernameValidator()], verbose_name='username')),
('first_name', models.CharField(blank=True, max_length=150, verbose_name='first name')),
('last_name', models.CharField(blank=True, max_length=150, verbose_name='last name')),
('email', models.EmailField(blank=True, max_length=254, verbose_name='email address')),
('is_staff', models.BooleanField(default=False, help_text='Designates whether the user can log into this admin site.', verbose_name='staff status')),
('is_active', models.BooleanField(default=True, help_text='Designates whether this user should be treated as active. Unselect this instead of deleting accounts.', verbose_name='active')),
('date_joined', models.DateTimeField(default=django.utils.timezone.now, verbose_name='date joined')),
('groups', models.ManyToManyField(blank=True, help_text='The groups this user belongs to. A user will get all permissions granted to each of their groups.', related_name='user_set', related_query_name='user', to='auth.Group', verbose_name='groups')),
('user_permissions', models.ManyToManyField(blank=True, help_text='Specific permissions for this user.', related_name='user_set', related_query_name='user', to='auth.Permission', verbose_name='user permissions')),
],
options={
'verbose_name': 'user',
'verbose_name_plural': 'users',
'abstract': False,
},
managers=[
('objects', django.contrib.auth.models.UserManager()),
],
),
]
23 changes: 23 additions & 0 deletions network/migrations/0002_repo.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
# Generated by Django 3.1.5 on 2021-01-29 16:57

from django.db import migrations, models


class Migration(migrations.Migration):

dependencies = [
('network', '0001_initial'),
]

operations = [
migrations.CreateModel(
name='Repo',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('repo_id', models.IntegerField()),
('name', models.CharField(max_length=64)),
('desc', models.CharField(max_length=128)),
('link', models.CharField(max_length=128)),
],
),
]
27 changes: 27 additions & 0 deletions network/migrations/0003_auto_20210129_1406.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
# Generated by Django 3.1.5 on 2021-01-29 17:06

from django.db import migrations, models


class Migration(migrations.Migration):

dependencies = [
('network', '0002_repo'),
]

operations = [
migrations.RemoveField(
model_name='repo',
name='repo_id',
),
migrations.AddField(
model_name='repo',
name='tag',
field=models.CharField(default='NA', max_length=64),
),
migrations.AlterField(
model_name='repo',
name='id',
field=models.IntegerField(primary_key=True, serialize=False),
),
]
18 changes: 18 additions & 0 deletions network/migrations/0004_auto_20210129_1420.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
# Generated by Django 3.1.5 on 2021-01-29 17:20

from django.db import migrations, models


class Migration(migrations.Migration):

dependencies = [
('network', '0003_auto_20210129_1406'),
]

operations = [
migrations.AlterField(
model_name='repo',
name='id',
field=models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID'),
),
]
25 changes: 25 additions & 0 deletions network/migrations/0005_auto_20210130_1025.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
# Generated by Django 3.1.5 on 2021-01-30 13:25

from django.db import migrations, models


class Migration(migrations.Migration):

dependencies = [
('network', '0004_auto_20210129_1420'),
]

operations = [
migrations.RemoveField(
model_name='repo',
name='tag',
),
migrations.CreateModel(
name='Tag',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('name', models.CharField(max_length=64)),
('repo', models.ManyToManyField(blank=True, related_name='tag', to='network.Repo')),
],
),
]
17 changes: 17 additions & 0 deletions network/migrations/0006_remove_tag_repo.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
# Generated by Django 3.1.5 on 2021-01-30 23:51

from django.db import migrations


class Migration(migrations.Migration):

dependencies = [
('network', '0005_auto_20210130_1025'),
]

operations = [
migrations.RemoveField(
model_name='tag',
name='repo',
),
]
18 changes: 18 additions & 0 deletions network/migrations/0007_tag_repos.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
# Generated by Django 3.1.5 on 2021-01-31 00:06

from django.db import migrations, models


class Migration(migrations.Migration):

dependencies = [
('network', '0006_remove_tag_repo'),
]

operations = [
migrations.AddField(
model_name='tag',
name='repos',
field=models.ManyToManyField(blank=True, related_name='tags', to='network.Repo'),
),
]
Loading