Skip to content
This repository was archived by the owner on Nov 28, 2025. It is now read-only.

Commit f572749

Browse files
authored
Merge pull request #225 from stack-of-tasks/pre-commit-ci-update-config
[pre-commit.ci] pre-commit autoupdate
2 parents ee5d70e + 0d64506 commit f572749

File tree

201 files changed

+1825
-1827
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

201 files changed

+1825
-1827
lines changed

.pre-commit-config.yaml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ ci:
22
autoupdate_branch: 'devel'
33
repos:
44
- repo: https://github.com/pre-commit/mirrors-clang-format
5-
rev: v20.1.8
5+
rev: v21.1.2
66
hooks:
77
- id: clang-format
88
args: ['--style={BasedOnStyle: Google,SortIncludes: false}']
@@ -24,8 +24,8 @@ repos:
2424
- id: fix-byte-order-marker
2525
- id: mixed-line-ending
2626
- id: trailing-whitespace
27-
- repo: https://github.com/psf/black
28-
rev: 25.1.0
27+
- repo: https://github.com/psf/black-pre-commit-mirror
28+
rev: 25.9.0
2929
hooks:
3030
- id: black
3131
- repo: https://github.com/PyCQA/flake8

include/sot/core/abstract-sot-external-interface.hh

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -27,13 +27,13 @@ class SOT_CORE_EXPORT NamedVector {
2727
NamedVector() {}
2828
~NamedVector() {}
2929

30-
const std::string &getName() const { return name_; }
30+
const std::string& getName() const { return name_; }
3131

32-
void setName(const std::string &aname) { name_ = aname; }
32+
void setName(const std::string& aname) { name_ = aname; }
3333

34-
const std::vector<double> &getValues() const { return values_; }
34+
const std::vector<double>& getValues() const { return values_; }
3535

36-
void setValues(const std::vector<double> &values) { values_ = values; }
36+
void setValues(const std::vector<double>& values) { values_ = values; }
3737
};
3838
typedef NamedVector SensorValues;
3939
typedef NamedVector ControlValues;
@@ -45,31 +45,31 @@ class SOT_CORE_EXPORT AbstractSotExternalInterface {
4545
virtual ~AbstractSotExternalInterface() {}
4646

4747
virtual void setupSetSensors(
48-
std::map<std::string, SensorValues> &sensorsIn) = 0;
48+
std::map<std::string, SensorValues>& sensorsIn) = 0;
4949

5050
virtual void nominalSetSensors(
51-
std::map<std::string, SensorValues> &sensorsIn) = 0;
51+
std::map<std::string, SensorValues>& sensorsIn) = 0;
5252

5353
virtual void cleanupSetSensors(
54-
std::map<std::string, SensorValues> &sensorsIn) = 0;
54+
std::map<std::string, SensorValues>& sensorsIn) = 0;
5555

5656
// Get control vector
5757
// \param map map string to vector of doubles. This method is expected to
5858
// fill in entry "control"
5959
// \param period time since last call.
60-
virtual void getControl(std::map<std::string, ControlValues> &,
61-
const double &period = 0) = 0;
60+
virtual void getControl(std::map<std::string, ControlValues>&,
61+
const double& period = 0) = 0;
6262
virtual void setSecondOrderIntegration(void) = 0;
6363
virtual void setNoIntegration(void) = 0;
6464
// Set the number of joints that are controlled
65-
virtual void setControlSize(const size_type &) = 0;
65+
virtual void setControlSize(const size_type&) = 0;
6666
};
6767
} // namespace sot
6868
} // namespace dynamicgraph
6969

70-
typedef dynamicgraph::sot::AbstractSotExternalInterface *
70+
typedef dynamicgraph::sot::AbstractSotExternalInterface*
7171
createSotExternalInterface_t();
7272
typedef void destroySotExternalInterface_t(
73-
dynamicgraph::sot::AbstractSotExternalInterface *);
73+
dynamicgraph::sot::AbstractSotExternalInterface*);
7474

7575
#endif // ABSTRACT_SOT_EXTERNAL_INTERFACE_HH

include/sot/core/additional-functions.hh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,8 +36,8 @@ class AdditionalFunctions {
3636
public:
3737
AdditionalFunctions();
3838
~AdditionalFunctions();
39-
static void cmdFlagSet(const std::string &cmd, std::istringstream &args,
40-
std::ostream &os);
39+
static void cmdFlagSet(const std::string& cmd, std::istringstream& args,
40+
std::ostream& os);
4141
};
4242

4343
} /* namespace sot */

include/sot/core/admittance-control-op-point.hh

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -64,13 +64,13 @@ class ADMITTANCECONTROLOPPOINT_EXPORT AdmittanceControlOpPoint
6464
EIGEN_MAKE_ALIGNED_OPERATOR_NEW
6565

6666
/* --- CONSTRUCTOR ---- */
67-
AdmittanceControlOpPoint(const std::string &name);
67+
AdmittanceControlOpPoint(const std::string& name);
6868
/**
6969
* @brief Initialize the entity
7070
*
7171
* @param[in] dt Time step of the control
7272
*/
73-
void init(const double &dt);
73+
void init(const double& dt);
7474

7575
/* --- SIGNALS --- */
7676
/// \brief Gain (6d) for the integration of the error on the force
@@ -104,7 +104,7 @@ class ADMITTANCECONTROLOPPOINT_EXPORT AdmittanceControlOpPoint
104104
void resetDq();
105105

106106
/* --- ENTITY INHERITANCE --- */
107-
virtual void display(std::ostream &os) const;
107+
virtual void display(std::ostream& os) const;
108108

109109
protected:
110110
/// Dimension of the force signals and of the output

include/sot/core/binary-int-to-uint.hh

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -40,20 +40,20 @@ namespace sot {
4040
class SOTBINARYINTTOUINT_EXPORT BinaryIntToUint : public dynamicgraph::Entity {
4141
public:
4242
static const std::string CLASS_NAME;
43-
virtual const std::string &getClassName(void) const { return CLASS_NAME; }
43+
virtual const std::string& getClassName(void) const { return CLASS_NAME; }
4444

4545
/* --- SIGNALS ------------------------------------------------------------ */
4646
public:
4747
dynamicgraph::SignalPtr<int, sigtime_t> binaryIntSIN;
4848
dynamicgraph::SignalTimeDependent<unsigned, sigtime_t> binaryUintSOUT;
4949

5050
public:
51-
BinaryIntToUint(const std::string &name);
51+
BinaryIntToUint(const std::string& name);
5252
virtual ~BinaryIntToUint() {}
5353

54-
virtual unsigned int &computeOutput(unsigned int &res, sigtime_t time);
54+
virtual unsigned int& computeOutput(unsigned int& res, sigtime_t time);
5555

56-
virtual void display(std::ostream &os) const;
56+
virtual void display(std::ostream& os) const;
5757
};
5858

5959
} /* namespace sot */

include/sot/core/binary-op.hh

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -49,10 +49,10 @@ class BinaryOp : public Entity {
4949
static std::string getTypeIn2Name(void) { return Operator::nameTypeIn2(); }
5050
static std::string getTypeOutName(void) { return Operator::nameTypeOut(); }
5151
static const std::string CLASS_NAME;
52-
virtual const std::string &getClassName() const { return CLASS_NAME; }
52+
virtual const std::string& getClassName() const { return CLASS_NAME; }
5353
std::string getDocString() const { return op.getDocString(); }
5454

55-
BinaryOp(const std::string &name)
55+
BinaryOp(const std::string& name)
5656
: Entity(name),
5757
SIN1(NULL, BinaryOp::CLASS_NAME + "(" + name + ")::input(" +
5858
getTypeIn1Name() + ")::sin1"),
@@ -73,9 +73,9 @@ class BinaryOp : public Entity {
7373
SignalTimeDependent<Tout, sigtime_t> SOUT;
7474

7575
protected:
76-
Tout &computeOperation(Tout &res, sigtime_t time) {
77-
const Tin1 &x1 = SIN1(time);
78-
const Tin2 &x2 = SIN2(time);
76+
Tout& computeOperation(Tout& res, sigtime_t time) {
77+
const Tin1& x1 = SIN1(time);
78+
const Tin2& x2 = SIN2(time);
7979
op(x1, x2, res);
8080
return res;
8181
}

include/sot/core/causal-filter.hh

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -54,15 +54,15 @@ class CausalFilter {
5454
5555
xSize is
5656
*/
57-
CausalFilter(const double &timestep, const size_type &xSize,
58-
const Eigen::VectorXd &filter_numerator,
59-
const Eigen::VectorXd &filter_denominator);
57+
CausalFilter(const double& timestep, const size_type& xSize,
58+
const Eigen::VectorXd& filter_numerator,
59+
const Eigen::VectorXd& filter_denominator);
6060

61-
void get_x_dx_ddx(const Eigen::VectorXd &base_x,
62-
Eigen::VectorXd &x_output_dx_ddx);
61+
void get_x_dx_ddx(const Eigen::VectorXd& base_x,
62+
Eigen::VectorXd& x_output_dx_ddx);
6363

64-
void switch_filter(const Eigen::VectorXd &filter_numerator,
65-
const Eigen::VectorXd &filter_denominator);
64+
void switch_filter(const Eigen::VectorXd& filter_numerator,
65+
const Eigen::VectorXd& filter_denominator);
6666

6767
private:
6868
/// sampling timestep of the input signal

include/sot/core/clamp-workspace.hh

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ namespace sot {
4747
class SOTCLAMPWORKSPACE_EXPORT ClampWorkspace : public dynamicgraph::Entity {
4848
public:
4949
static const std::string CLASS_NAME;
50-
virtual const std::string &getClassName(void) const { return CLASS_NAME; }
50+
virtual const std::string& getClassName(void) const { return CLASS_NAME; }
5151

5252
/* --- SIGNALS ------------------------------------------------------------ */
5353
public:
@@ -59,18 +59,18 @@ class SOTCLAMPWORKSPACE_EXPORT ClampWorkspace : public dynamicgraph::Entity {
5959
dynamicgraph::SignalTimeDependent<MatrixHomogeneous, sigtime_t> handrefSOUT;
6060

6161
public:
62-
ClampWorkspace(const std::string &name);
62+
ClampWorkspace(const std::string& name);
6363
virtual ~ClampWorkspace(void) {}
6464

6565
void update(sigtime_t time);
6666

67-
virtual dynamicgraph::Matrix &computeOutput(dynamicgraph::Matrix &res,
67+
virtual dynamicgraph::Matrix& computeOutput(dynamicgraph::Matrix& res,
6868
sigtime_t time);
69-
virtual dynamicgraph::Matrix &computeOutputBar(dynamicgraph::Matrix &res,
69+
virtual dynamicgraph::Matrix& computeOutputBar(dynamicgraph::Matrix& res,
7070
sigtime_t time);
71-
virtual MatrixHomogeneous &computeRef(MatrixHomogeneous &res, sigtime_t time);
71+
virtual MatrixHomogeneous& computeRef(MatrixHomogeneous& res, sigtime_t time);
7272

73-
virtual void display(std::ostream &) const;
73+
virtual void display(std::ostream&) const;
7474

7575
private:
7676
sigtime_t timeUpdate;

include/sot/core/com-freezer.hh

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -45,15 +45,15 @@ namespace sot {
4545
class SOTCOMFREEZER_EXPORT CoMFreezer : public dynamicgraph::Entity {
4646
public:
4747
static const std::string CLASS_NAME;
48-
virtual const std::string &getClassName() const { return CLASS_NAME; }
48+
virtual const std::string& getClassName() const { return CLASS_NAME; }
4949

5050
private:
5151
dynamicgraph::Vector m_lastCoM;
5252
bool m_previousPGInProcess;
5353
sigtime_t m_lastStopTime;
5454

5555
public: /* --- CONSTRUCTION --- */
56-
CoMFreezer(const std::string &name);
56+
CoMFreezer(const std::string& name);
5757
virtual ~CoMFreezer(void);
5858

5959
public: /* --- SIGNAL --- */
@@ -63,11 +63,11 @@ class SOTCOMFREEZER_EXPORT CoMFreezer : public dynamicgraph::Entity {
6363
freezedCoMSOUT;
6464

6565
public: /* --- FUNCTION --- */
66-
dynamicgraph::Vector &computeFreezedCoM(dynamicgraph::Vector &freezedCoM,
67-
const sigtime_t &time);
66+
dynamicgraph::Vector& computeFreezedCoM(dynamicgraph::Vector& freezedCoM,
67+
const sigtime_t& time);
6868

6969
public: /* --- PARAMS --- */
70-
virtual void display(std::ostream &os) const;
70+
virtual void display(std::ostream& os) const;
7171
};
7272

7373
} /* namespace sot */

include/sot/core/contiifstream.hh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -42,9 +42,9 @@ class SOT_CORE_EXPORT Contiifstream {
4242
bool first;
4343

4444
public: /* --- Constructor --- */
45-
Contiifstream(const std::string &n = "");
45+
Contiifstream(const std::string& n = "");
4646
~Contiifstream(void);
47-
void open(const std::string &n) {
47+
void open(const std::string& n) {
4848
filename = n;
4949
cursor = 0;
5050
}

0 commit comments

Comments
 (0)