This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
if: github.ref == 'refs/heads/master' | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v2 | |
- id: next_version | |
uses: zwaldowski/semver-release-action@v1 | |
with: | |
bump: patch | |
prefix: api_server_v | |
github_token: ${{ secrets.GITHUB_TOKEN }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Monorepo PR Repo Labeler | |
on: | |
pull_request: | |
types: [opened] | |
branches: | |
- main | |
jobs: | |
labelPR: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
on: | |
push: | |
branches: | |
- main | |
paths: | |
- "amazon_scraper/**" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
m = Prophet() | |
m.add_regressor('peak_reg') | |
m.add_seasonality('peak_period_start',period=22,fourier_order=1) | |
m.add_seasonality('peak_period_end',period=36,fourier_order=1) | |
m.fit(df) | |
future = m.make_future_dataframe(periods=28) | |
future['ds_ts'] = pd.to_datetime(future['ds']) | |
future['no_school'] = pd.Timestamp(datetime(2020,2,24)) | |
future['since_no_school'] = future['ds_ts'].sub(future['no_school'], axis=0).dt.days | |
future['peak_reg'] = future['since_no_school'].apply(peak_days ) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
m = Prophet() | |
m.fit(df) | |
future = m.make_future_dataframe(periods=50) | |
forecast = m.predict(future) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
bs= df.loc[df['sigla_provincia'] == 'BS'] | |
bs = bs.sort_values(by=['data']) | |
bs = bs.drop(['stato', 'codice_regione', 'denominazione_regione','codice_provincia','sigla_provincia','lat','long','denominazione_provincia'], axis=1) | |
bs = bs.reset_index(drop=True) | |
bs.columns = ['ds','y'] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
sealed trait ErrorInfo | |
case class NotFound(what: String) extends ErrorInfo | |
case class Unauthorized(realm: String) extends ErrorInfo | |
case class Unknown(code: Int, msg: String) extends ErrorInfo | |
case object NoContent extends ErrorInfo | |
case class Conflict(what: String) extends ErrorInfo | |
case class ErrorCodeAndMessage(code: String, message: String) | |
case class GenericErrorInfo(errors: List[ErrorCodeAndMessage]) extends ErrorInfo | |
def baseEndpoint(basePath: String): Endpoint[Unit, ErrorInfo, Unit, Nothing] = { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package com.github.sammyrulez | |
import tapir._ | |
import tapir.json.circe._ | |
import io.circe.generic.auto._ | |
import scala.concurrent.{ ExecutionContext, Future } | |
import akka.http.scaladsl.server.Route | |
object CharRoutes { | |
import tapir.server.akkahttp._ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-echo 'PHNldHRpbmdzIHhtbG5zPSJodHRwOi8vbWF2ZW4uYXBhY2hlLm9yZy9TRVRUSU5HUy8xLjAuMCIKICAgICAgICAgIHhtbG5zOnhzaT0iaHR0cDovL3d3dy53My5vcmcvMjAwMS9YTUxTY2hlbWEtaW5zdGFuY2UiCiAgICAgICAgICB4c2k6c2NoZW1hTG9jYXRpb249Imh0dHA6Ly9tYXZlbi5hcGFjaGUub3JnL1NFVFRJTkdTLzEuMC4wCiAgICAgIGh0dHBzOi8vbWF2ZW4uYXBhY2hlLm9yZy94c2Qvc2V0dGluZ3MtMS4wLjAueHNkIj4KICAgIDxzZXJ2ZXJzPgogICAgICAgIDxzZXJ2ZXI+CiAgICAgICAgICAgIDxpZD54eXotcmVsZWFzZXM8L2lkPgogICAgICAgICAgICA8dXNlcm5hbWU+JHtteS5yZXBvLnVzZXJ9PC91c2VybmFtZT4KICAgICAgICAgICAgPHBhc3N3b3JkPiR7bXkucmVwby5wYXNzd29yZH08L3Bhc3N3b3JkPgogICAgICAgICAgICA8IS0tIGRvIHlvdSByZWFsbHkgdGhpbmsgSSB3b3VsZCBoYXZlIHB1dCB0aGUgcGFzc293cmQgaGVyZT8gLS0+CiAgICAgICAgPC9zZXJ2ZXI+CiAgICAgICAgPHNlcnZlcj4KICAgICAgICAgICAgPGlkPnh5ei1zbmFwc2hvdHM8L2lkPgogICAgICAgICAgICAgPHVzZXJuYW1lPiR7bXkucmVwby51c2VyfTwvdXNlcm5hbWU+CiAgICAgICAgICAgIDxwYXNzd29yZD4ke215LnJlcG8ucGFzc3dvcmR9PC9wYXNzd29yZD4KICAgICAgICA8L3NlcnZlcj4KICAgIDwvc2VydmVycz4KPC9zZXR0aW5ncw==' | base64 - decode > settings.xml |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<settings xmlns="http://maven.apache.org/SETTINGS/1.0.0" | |
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" | |
xsi:schemaLocation="http://maven.apache.org/SETTINGS/1.0.0 | |
https://maven.apache.org/xsd/settings-1.0.0.xsd"> | |
<servers> | |
<server> | |
<id>xyz-releases</id> | |
<username>${my.repo.user}</username> | |
<password>${my.repo.password}</password> | |
</server> |
NewerOlder