Giter Club home page Giter Club logo

mrwoo's Introduction

mrwoo

mrwoo helps you find interested jobs posted on job search sites in Taiwan. Now, view job opportunities using CLI on the terminal!

Why use mrwoo

If you have the following conditions, recommend you try it.

  • Tired of searching back and forth on multiple job sites.
  • The same vacancies keep popping up.
  • Don't want to see job openings that I'm not interested in.

supported job sites

Requirements

  • Python >= 3.11.2
  • Git latest version

Installation

Step 1: Get the source code

git clone https://github.com/anntsai2356/mrwoo.git --depth=1

Tip: Use --depth=1 to get the latest instead of the whole repository.

Step 2: Set commend path

Find the bin folder path and append to the PATH variable in ZSH or BASH.

  • export PATH="<bin_folder_path>:$PATH": export PATH setting
  • <bin_folder_path>: bin folder path

Note: Replace <bin_folder_path> to a true path.

Take ZSH for example:

# append to .zshrc
echo 'export PATH="<bin_folder_path>:$PATH"' >> ~/.zshrc

# restart .zshrc
source ~/.zshrc

Step 3: Test

Check the command is work.

$ mrwoo -h
usage: mrwoo [-h] {fetch,browse} ...

mrwoo is a command line tool to browse jobs in the terminal.

positional arguments:
  {fetch,browse}
    fetch         fetch the job information from certain sites.
    browse        browse the job information from the specific file.

options:
  -h, --help      show this help message and exit

Usage

Basic

# Job search by keyword "engineer" and export file in data folder.
# Default file name is jobs_YYYY-MM-DD.csv.
mrwoo fetch engineer

# View jobs one by one.
mrwoo browse data/jobs_YYYY-MM-DD.csv

Advanced

# Job search by keyword "engineer" and "php" to specific file path.
# Then combine jobs to specific destination.
mrwoo fetch engineer -C data/engineer.csv -f data/jobs.csv
mrwoo fetch php -C data/php.csv -f data/jobs.csv

# View jobs one by one.
mrwoo browse data/jobs.csv

mrwoo's People

Contributors

anntsai2356 avatar vnaonlu avatar

Watchers

Kostas Georgiou avatar  avatar

mrwoo's Issues

Error location in cakeresume parser

I got an error when parsed cake resume data, please help😢

(should use .json to open file)
3.response.txt

error message:

Traceback (most recent call last):
  File "/Users/anntsai/Repositories/mrwoo/cakeresume_tester.py", line 68, in <module>
    total_jobs = getJobsFromPages(page_count)
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/anntsai/Repositories/mrwoo/cakeresume_tester.py", line 50, in getJobsFromPages
    page_jobs = parser.parse(decoded_content)
                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/anntsai/Repositories/mrwoo/src/jobs_parser.py", line 20, in parse
    return self._parseImpl(obj)
           ^^^^^^^^^^^^^^^^^^^^
  File "/Users/anntsai/Repositories/mrwoo/src/jobs_parser.py", line 91, in _parseImpl
    detail.location = self._getValueRecursively(info, 'flat_location_list')[0]
                      ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^
IndexError: list index out of range

url setting:

params = {
    "x-algolia-agent": "Algolia for JavaScript (4.14.2); Browser (lite); instantsearch.js (4.49.1); react (18.2.0); react-instantsearch (6.38.1); react-instantsearch-hooks (6.38.1); JS Helper (3.11.1)",
    "x-algolia-api-key": "OTQ1MjI1MmYwNmM0YmQ0MjIxMTZhNzM1NWNhZGQ0YzQ5OGM2Y2I5NzQ1ZTM1MjViMTMyMTE0NTk3MTZkODI2NHZhbGlkVW50aWw9MTY3OTMwODQ5NSZyZXN0cmljdEluZGljZXM9Sm9iJTJDSm9iX29yZGVyX2J5X2NvbnRlbnRfdXBkYXRlZF9hdCUyQ0pvYl9wbGF5Z3JvdW5kJTJDUGFnZSUyQ1BhZ2Vfb3JkZXJfYnlfY29udGVudF91cGRhdGVkX2F0JmZpbHRlcnM9YWFzbV9zdGF0ZSUzQSslMjJjcmVhdGVkJTIyK0FORCtub2luZGV4JTNBK2ZhbHNlJmhpdHNQZXJQYWdlPTEwJmF0dHJpYnV0ZXNUb1NuaXBwZXQ9JTVCJTIyZGVzY3JpcHRpb25fcGxhaW5fdGV4dCUzQTgwJTIyJTVEJmhpZ2hsaWdodFByZVRhZz0lM0NtYXJrJTNFJmhpZ2hsaWdodFBvc3RUYWc9JTNDJTJGbWFyayUzRQ==",
    "x-algolia-application-id": "966RG9M3EK",
}

root_url = "https://966rg9m3ek-dsn.algolia.net/1/indexes/*/queries?"

search_json = {
    "requests": [
        {
            "indexName": "Job",
            "params": "query=php&userToken=39196&page=3",
        }
    ]
}

url = root_url + urlencode(params)
response = requests.post(url, json=search_json)

cakeresume request error

There is error message:

Traceback (most recent call last):
  File "/Users/anntsai/Repositories/mrwoo/src/job_integrator_test.py", line 163, in <module>
    jobs = request_helper.getJobsList()
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/anntsai/Repositories/mrwoo/src/jobs_request.py", line 53, in getJobsList
    while self._getJobs(result):
          ^^^^^^^^^^^^^^^^^^^^^
  File "/Users/anntsai/Repositories/mrwoo/src/jobs_request.py", line 131, in _getJobs
    self._total_pages = data["results"][0]["nbPages"]
                        ~~~~^^^^^^^^^^^
KeyError: 'results'

There is error response:

{"message":"\"validUntil\" parameter expired (less than current date)","status":400}

Should check API response status is 200.
If not 200, skip it and print warning message.

you can run it to get the same status:

from jobs_request import RequestHelperHandle
from site_types import SiteType

site_type = SiteType.CAKERESUME
request_helper = RequestHelperHandle.get(site_type)
jobs = request_helper.getJobsList()

Separate upsert and request

Let upsert method be pure. Don't be related to request.
Input "from_file" and "to_file" into upsert method.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.