Skip to content

Commit e7135e0

Browse files
committed
Refactor codebase
1 parent 8723e71 commit e7135e0

27 files changed

+3790
-3950
lines changed

.gitignore

Lines changed: 18 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,24 @@
1-
/target
2-
/classes
3-
/checkouts
4-
pom.xml.asc
5-
*.jar
1+
!.yarn/patches
2+
!.yarn/plugins
3+
!.yarn/releases
4+
!.yarn/sdks
5+
!.yarn/versions
66
*.class
7+
*.jar
8+
.pnp.*
9+
.shadow-cljs
10+
.yarn/*
11+
/*-init.clj
12+
/.cpcache
713
/.lein-*
814
/.nrepl-port
9-
/*-init.clj
15+
/.rebel*
16+
/checkouts
17+
/classes
1018
/doc/dist
19+
/nashorn_code_cache
20+
/node_modules
1121
/out
1222
/repl
13-
/node_modules
14-
/nashorn_code_cache
15-
/.cpcache
16-
/.rebel*
23+
/target
24+
pom.xml.asc

.yarnrc.yml

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
enableGlobalCache: true
2+
3+
enableImmutableCache: false
4+
5+
enableImmutableInstalls: false
6+
7+
enableTelemetry: false
8+
9+
nodeLinker: node-modules

CHANGES.md

Lines changed: 49 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,54 @@
11
# Changelog #
22

3+
## Version 2.2 ##
4+
5+
- Fix recursion error on ignore operator
6+
7+
## Version 2.1 ##
8+
9+
- Make seed optional for `reduce`
10+
- Make seed optional for `scan`
11+
12+
13+
## Version 2.0 ##
14+
15+
This version few numer of BREAKING CHANGES that should be considered
16+
before upgrade. All of them are pretty easy to adapt.
17+
18+
As this is a breaking change, we decide to rename the `beicon.core`
19+
namespace with `beicon.v2` namespace, so the people can continue using
20+
the old API and the old package if they want without a conflict with
21+
the new version.
22+
23+
This is a major API cleanup and adapt it more to RX convention of
24+
using `rx/pipe` operator for compose transformations.
25+
26+
Relevant changes:
27+
28+
- The internal `rx/pipe` function inverts the arguments order for to
29+
be easy to use with `->>`.
30+
- Make the `rx/pipe` as public API useful for use custom defined
31+
operators.
32+
- Add `beicon.v2.ops` with operator only functions.
33+
- Remove the `flat-map` alias (use `merge-map`).
34+
- The `first` operator now becomes an alias for `(take 1)`.
35+
- The `last` operator becomes an alias for `(take-last 1)`.
36+
- Make the `seed` parameter to `reduce` as mandatory.
37+
- Make the `seed` parameter to `scan` as mandatory.
38+
- Replace multiarity `with-latest-from` with a specific operator
39+
`with-latest-from*` that can be used through the `rx/pipe`
40+
observable chain helper. Mainly for reduce code complexity.
41+
- Remove the `do` alias for `tap`
42+
- Remove the `log` and `pr-log` operator
43+
- Replace `dedupe` and `dedupe'` with operator only
44+
`distinct-contiguous*` and `distinct*` for make it more similar to
45+
rxjs API.
46+
- The `delay-when` operator arguments order changed to be the same as
47+
rxjs
48+
- Remove `delay-emit`
49+
- Replace `subs` with `subs!`
50+
51+
352
## Version 2021.07.05-1 ##
453

554
- Fix bug on `delay-emit` operator.
@@ -21,7 +70,6 @@ BREAKING CHANGES: `zip` no longer accepts acoomulator function.
2170
- Minor improvements on `concat` and `zip` constructors.
2271

2372

24-
2573
## Version 2021.06.02-0 ##
2674

2775
- Update bundled rxjs to 7.1.0

LICENSE

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
Copyright (c) 2015-2016 Andrey Antukh <[email protected]>
1+
Copyright (c) 2015-2024 Andrey Antukh <[email protected]>
22

33
All rights reserved.
44

build.clj

Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
(ns build
2+
(:refer-clojure :exclude [compile])
3+
(:require
4+
[clojure.tools.build.api :as b]
5+
[cljs.build.api :as api]))
6+
7+
(def lib 'funcool/beicon2)
8+
(def version (format "2.0-%s" (b/git-count-revs nil)))
9+
(def class-dir "target/classes")
10+
(def basis (b/create-basis {:project "deps.edn"}))
11+
(def jar-file (format "target/%s-%s.jar" (name lib) version))
12+
13+
(defn clean [_]
14+
(b/delete {:path "target"}))
15+
16+
(defn jar [_]
17+
(b/write-pom
18+
{:class-dir class-dir
19+
:lib lib
20+
:version version
21+
:basis basis
22+
:src-dirs ["src"]})
23+
24+
(b/copy-dir
25+
{:src-dirs ["src" "resources"]
26+
:target-dir class-dir})
27+
28+
(b/jar
29+
{:class-dir class-dir
30+
:jar-file jar-file}))
31+
32+
(defn install [_]
33+
(b/install {:basis basis
34+
:lib lib
35+
:version version
36+
:jar-file jar-file
37+
:class-dir class-dir}))
38+
39+
(defn clojars [_]
40+
(b/process
41+
{:command-args ["mvn"
42+
"deploy:deploy-file"
43+
(str "-Dfile=" jar-file)
44+
"-DpomFile=target/classes/META-INF/maven/funcool/beicon/pom.xml"
45+
"-DrepositoryId=clojars"
46+
"-Durl=https://clojars.org/repo/"]}))

deps.edn

Lines changed: 24 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,27 +1,37 @@
1-
{:paths ["src" "assets"]
1+
{:paths ["src" "resources" "target/classes"],
22
:aliases
33
{:dev
44
{:extra-deps
5-
{org.clojure/clojurescript {:mvn/version "1.10.844"}
6-
org.clojure/clojure {:mvn/version "1.10.3"}
7-
com.bhauman/rebel-readline-cljs {:mvn/version "RELEASE"}
8-
com.bhauman/rebel-readline {:mvn/version "RELEASE"}
9-
funcool/promesa {:mvn/version "RELEASE"}}
10-
:extra-paths ["test" "dev-resources"]}
5+
{com.bhauman/rebel-readline-cljs {:mvn/version "RELEASE"},
6+
com.bhauman/rebel-readline {:mvn/version "RELEASE"},
7+
org.clojure/tools.namespace {:mvn/version "RELEASE"},
8+
org.clojure/core.async {:mvn/version "1.6.673"}
9+
criterium/criterium {:mvn/version "RELEASE"}
10+
thheller/shadow-cljs {:mvn/version "RELEASE"}}
11+
:extra-paths ["test" "dev" "src"]}
1112

12-
:ancient
13-
{:main-opts ["-m" "deps-ancient.deps-ancient"],
14-
:extra-deps {deps-ancient/deps-ancient {:mvn/version "RELEASE"}}}
13+
:repl
14+
{:main-opts ["-m" "rebel-readline.main"]}
15+
16+
:shadow-cljs
17+
{:main-opts ["-m" "shadow.cljs.devtools.cli"]}
1518

1619
:codox
1720
{:extra-deps
1821
{codox/codox {:mvn/version "RELEASE"}
1922
org.clojure/tools.reader {:mvn/version "RELEASE"}
2023
codox-theme-rdash/codox-theme-rdash {:mvn/version "RELEASE"}}}
2124

22-
:jar
23-
{:replace-deps {com.github.seancorfield/depstar {:mvn/version "RELEASE"}}
24-
:exec-fn hf.depstar/jar
25-
:exec-args {:jar "target/beicon.jar"}}}}
2625

26+
:build
27+
{:extra-deps
28+
{io.github.clojure/tools.build {:git/tag "v0.9.3" :git/sha "e537cd1"}
29+
org.clojure/clojurescript {:mvn/version "RELEASE"}
30+
org.clojure/tools.deps.alpha {:mvn/version "RELEASE"}}
31+
:ns-default build}
2732

33+
:outdated
34+
{:extra-deps
35+
{com.github.liquidz/antq {:mvn/version "RELEASE"}
36+
org.slf4j/slf4j-nop {:mvn/version "RELEASE"}}
37+
:main-opts ["-m" "antq.core"]}}}

0 commit comments

Comments
 (0)